This is the GUI interface that provides a
a way to edit an AclEntry
AclEntryEdit is simply a JPanel Subclass that
is placed inside of a JDialog object so that the
user can specify the information that goes into
an AclEntry object.
This class will create various objects that implement the
Although its name suggests that this is a Java object Factory,
in fact it is not.
Adds a TupleSpace object to this Transaction object so that any operation
on an added space will be treated as part of this Transaction object if
enclosed between a beginTrans() and commitTrans()/abortTrans() operations
This is the authentication method that is invoked by the server when
it has the userid and password in hand (instead of an ObjectStream)
It will then validate the user/key combination by checking the
Hashtable where we have stored all the user/key combinations.
copyToLocal will copy the URL data from the Server to a local file
It will do the copy by specifing a URL that points to the HTTP server
maintained by TSpaces and using it to read the file and serve it to
decrement the semaphore, make sure your code is able to call this method ---
wherever you call decr from had better not be holding locks that are needed
for the other part to call incr
We support the caller specifing a max waittime after which it will
Use wants to add a new User to the selected
group (or user) This is similar to adding
a group but you will be asked for a password and
the userid and password will be added to a
list of users and groups.
Needed because all classes that go in a Field of a Tuple must have an
equals operator defined; even though the exception classes only go in
there to be passed back to the client and are never put into a space,
this is the way it is for now.
Method to return a Vector of all attributes
For code consistency and security, the Vector returned is actually
just a clone of the Vector, so all additions to the attribute list
and removals of attributes have to be done by using the class methods
provided in this class.
Get the child tuple ids of the current Tuple
we need this on the client side because we
cannot get the list of tuples using the server-side methods,
ie: db.fetchTupleById(...) in "getTuple(...)"
after we get this, we can manually read each tuple by it's
Return a reference to the current TSServer instance
If it returns null then maybe you are a client and not a server
but if you are running a client in the same Java Virtual Machine as the
server than you would get the refernce to the server even though you are
just a lowly client.
Do I handle this command on this argument?
For now, always say yes because the factory will only call us on
the command strings that we handle and we operate on all types of tuples
When each handler only handles one command, can tighten this up.
Return true if the current time is greater than the
Tuple (_timeStamp + _expire)
Normally this should only be done by the server since the
_timestamp is set by the server and the client and
server clocks may not be in sync.
This is code to test the handler by simulating what a client
application would do to load a special handler and then invode the
the new commands.Normally this code would be part of the application
that is going to to make use of the handler.
PrintText accepts "PrintText"" requests from TupleSpace and
issues a specified command to send the specified text to
The PrintText service is started by issuing the java invocation and
specifying the PrinterName, PrintCommand and FileDirectory as parameters
SendMail accepts "SendMail" requests from TupleSpace and
sends the specified message to the specified userid
The SendMail service is started by issuing the java invocation and
specifying the SMTP Host system as a parameter
java com.ibm.tspaces.examples.services.SendMail mail.sys.com
A client that wants to use the services needs to only do the following
Send a response to the client,
All responses should come through here!
If the communication fails we disable all further communication with this
port, indicate that TSIOHandler should stop and return false to the caller.
Set default username to be used for access control for all spaces
in this virtual mmachine It will be used in the TupleSpace Constructor
if not specified as a parameter and it will also be used for static commands
issued prior to the constructor which setup a server connection
Returns our best guess at the potential size of the result of this query
For XMLQueries this is hard to say, but this is really an issue of how
many documents of each DTD type are stored inside the TSDB.
Create a TSServer using the specified parameters
It will use the information that is either passed to the
construtor as parameters or is in the Configuration file to
start up the pieces of the TSServer.
TstServer accepts "TstServer"" requests from TupleSpace and
simulates the processing of the request
The TstServer service is started by issuing the java invocation and
specifying the TupleSpace host name as parameters