|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--jwo.vfc.hub.Request
Class for encapsulating a Hub - Client request. Can be used for sending messages from Hub to Client and Client to Hub. Each request will typically store a single line message and data to transfer.
Constructor Summary | |
Request()
Creates a request with blank message. |
|
Request(String message)
Creates a request containing a given message. |
|
Request(String message,
String userName,
String password)
Creates a request containing a given message. |
Method Summary | |
boolean |
containsFile()
Reports whether file is contained within request. |
boolean |
containsMetadata()
Reports whether metadata are contained within request. |
boolean |
getAbsoluteFileName()
Reports the absolute file name priviliges. |
byte[] |
getData()
Get the data stored in the request. |
String |
getFileName()
Get the name of the file to write. |
String |
getMessage()
Get the 1 line message that is encapsulated within the request. |
String |
getMetadata()
Retrieves stored metadata |
String |
getPassword()
Gets the password sent in the request. |
String |
getUserName()
Gets the username sent in the request. |
void |
readFile(String fileName)
Reads a given file name and stores the contents. |
void |
setAbsoluteFileName(boolean abs)
Sets the absolute file name priviliges. |
void |
setFileName(String fileName)
Sets the name of the file to write. |
void |
setMetadata(String metadata)
Stores some metadata. |
void |
writeFile(String fileName)
Writes the data to a given file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Request()
public Request(String message)
message
- Message to send as request.public Request(String message, String userName, String password)
message
- Message to send as request.userName
- User name.password
- Password.Method Detail |
public String getMessage()
public byte[] getData()
public String getUserName()
public String getPassword()
public boolean containsFile()
public String getFileName()
public void setFileName(String fileName)
fileName
- Name of file to write.public boolean getAbsoluteFileName()
public void setAbsoluteFileName(boolean abs)
abs
- Allows absolute file names to be used if set to true.public boolean containsMetadata()
public void setMetadata(String metadata)
metadata
- Metadata to store.public String getMetadata()
public void readFile(String fileName)
fileName
- Name of file to read.setAbsoluteFileName(boolean)
public void writeFile(String fileName)
fileName
- Name of file create.setAbsoluteFileName(boolean)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |