org.apache.slide.common
Interface NamespaceAccessToken

All Superinterfaces:
javax.transaction.UserTransaction
All Known Implementing Classes:
NamespaceAccessTokenImpl

public interface NamespaceAccessToken
extends javax.transaction.UserTransaction

The NamespaceAccessToken is an interface used to completely hide the real Namespace object reference from the client application. It is used by Slide to authenticate and control any operations on the namespace.

Using the NamespaceAccessToken, the application can obtain access to the helper interfaces (Content, Lock, Macro, Security and Structure).

The NamespaceAccessToken object implements the UserTransaction interface (see the Java Transaction API documentation for more details) to allow the client to control transaction demarcation.

Version:
$Revision: 1.13 $
Author:
Remy Maucherat

Method Summary
 void disconnect()
          Disconnect.
 void exportData(SlideToken token, java.io.Writer writer)
          Saves Slide Data to XML.
 void exportData(SlideToken token, java.io.Writer writer, java.lang.String startNode)
          Saves Slide Data to XML.
 Content getContentHelper()
          Get the version helper.
 Lock getLockHelper()
          Get the lock helper.
 Logger getLogger()
          Get namespace logger.
 Macro getMacroHelper()
          Get the macro helper.
 java.lang.String getName()
          Get namespace name.
 NamespaceConfig getNamespaceConfig()
          Retrive the namespace configuration.
 Security getSecurityHelper()
          Get the security helper.
 Structure getStructureHelper()
          Get the data helper.
 void importData(SlideToken token, Configuration objectNodeConfiguration)
          Import data from configuration object.
 void importData(SlideToken token, java.io.Reader reader)
          Import data from reader.
 
Methods inherited from interface javax.transaction.UserTransaction
begin, commit, getStatus, rollback, setRollbackOnly, setTransactionTimeout
 

Method Detail

getNamespaceConfig

public NamespaceConfig getNamespaceConfig()
Retrive the namespace configuration.
Returns:
NamespaceConfig Namespace configuration

importData

public void importData(SlideToken token,
                       Configuration objectNodeConfiguration)
                throws ConfigurationException,
                       UnknownObjectClassException,
                       ServiceAccessException
Import data from configuration object.
Parameters:
token - SlideToken, used for access to the namespace
objectNodeConfiguration - Configuration object
Throws:
ConfigurationException - Something went wrong during the reading of the XML
UnknownObjectClassException - Object class not found
ServiceAccessException - Error accessing service

importData

public void importData(SlideToken token,
                       java.io.Reader reader)
                throws ConfigurationException,
                       UnknownObjectClassException,
                       ServiceAccessException,
                       org.xml.sax.SAXException,
                       java.io.IOException
Import data from reader.
Parameters:
token - SlideToken, used for access to the namespace
reader - Reader
Throws:
ConfigurationException - Something went wrong during the reading of the XML
UnknownObjectClassException - Object class not found
ServiceAccessException - Error accessing service

exportData

public void exportData(SlideToken token,
                       java.io.Writer writer)
                throws SlideException
Saves Slide Data to XML.
Parameters:
writer - Writer
Throws:
SlideException -  

exportData

public void exportData(SlideToken token,
                       java.io.Writer writer,
                       java.lang.String startNode)
                throws SlideException
Saves Slide Data to XML.
Parameters:
writer - Writer
startNode - Start generating XML from this node of the Slide tree
Throws:
SlideException -  

getStructureHelper

public Structure getStructureHelper()
Get the data helper.
Returns:
Data Data helper

getContentHelper

public Content getContentHelper()
Get the version helper.
Returns:
Version Version helper

getLockHelper

public Lock getLockHelper()
Get the lock helper.
Returns:
Lock Lock helper

getSecurityHelper

public Security getSecurityHelper()
Get the security helper.
Returns:
Security Security helper

getMacroHelper

public Macro getMacroHelper()
Get the macro helper.
Returns:
Macro Macro helper

disconnect

public void disconnect()
Disconnect.

getName

public java.lang.String getName()
Get namespace name.
Returns:
String namespace name.

getLogger

public Logger getLogger()
Get namespace logger.
Returns:
The logger associated with the namespace.