com.sage.orion.sdata.servlet.accpac
Class AccpacResourceContext

java.lang.Object
  extended by com.sage.orion.sdata.servlet.accpac.AccpacResourceContext
All Implemented Interfaces:
ResourceContext
Direct Known Subclasses:
ResourceContextImpl

public class AccpacResourceContext
extends java.lang.Object
implements ResourceContext


Constructor Summary
AccpacResourceContext()
           
 
Method Summary
 java.lang.Object get(java.lang.String tag)
          Gets the requested context element.
 com.sage.accpac.sm.Program getAccpacProgram()
          Gets the Accpac Program from the context block.
 boolean getIsStateful()
          Gets whether this context represents a stateful connection
 com.sage.accpac.sm.View openView(java.lang.String viewID)
          Opens a normal View with no associated resource definition.
 SDataView openView(java.lang.String viewID, Resource resource)
          Opens a new SDataView in the context
 void put(java.lang.String tag, java.lang.Object object)
          Adds the given tag and context object to the context.
 void setAccpacProgram(com.sage.accpac.sm.Program program)
          Sets the Accpac Program in the context block.
 void setIsStateful(boolean stateful)
          Sets whether this context represents a stateful connection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AccpacResourceContext

public AccpacResourceContext()
Method Detail

setAccpacProgram

public void setAccpacProgram(com.sage.accpac.sm.Program program)
Sets the Accpac Program in the context block.

Parameters:
program -

getAccpacProgram

public com.sage.accpac.sm.Program getAccpacProgram()
Gets the Accpac Program from the context block.

Returns:
the Program from the context block

setIsStateful

public void setIsStateful(boolean stateful)
Sets whether this context represents a stateful connection

Parameters:
stateful - Whether this context represents a stateful connection

getIsStateful

public boolean getIsStateful()
Gets whether this context represents a stateful connection

Returns:
Whether this context represents a stateful connection

openView

public com.sage.accpac.sm.View openView(java.lang.String viewID)
Opens a normal View with no associated resource definition.

Parameters:
viewID - the roto ID of the view to be opened
Returns:
the newly opened View

openView

public SDataView openView(java.lang.String viewID,
                          Resource resource)
Opens a new SDataView in the context

Parameters:
viewID - the roto ID of the view to be opened
resource - the resource that corresponds to the view
Returns:
the newly opened SDataView

put

public void put(java.lang.String tag,
                java.lang.Object object)
Description copied from interface: ResourceContext
Adds the given tag and context object to the context.

Specified by:
put in interface ResourceContext

get

public java.lang.Object get(java.lang.String tag)
Description copied from interface: ResourceContext
Gets the requested context element.

Specified by:
get in interface ResourceContext
Returns:
the requested context element. returns null if the element does not exist.


Copyright © 2011 Sage Software, Inc. All rights reserved.