public class DeviceContext extends Object
The device context is passed to the methods of a device interface. Each shared device has a device interface and a device context associated with it. The device context allows a single device interface to be used for multiple shared devices.
Constructor and Description |
---|
DeviceContext()
DeviceContext constructor.
|
DeviceContext(String devName)
Class constructor
|
DeviceContext(String devName,
String shareName)
Class constructor
|
Modifier and Type | Method and Description |
---|---|
void |
CloseContext()
Close the device context, free any resources allocated by the context
|
org.springframework.extensions.config.ConfigElement |
getConfigurationParameters()
Return the configuration parameters
|
String |
getDeviceName()
Return the device name.
|
String |
getShareName()
Return the shared device name
|
boolean |
hasConfigurationParameters()
Determine if the device context has any configuration parameters
|
boolean |
isAvailable()
Determine if the filesystem is available
|
void |
setAvailable(boolean avail)
Set the filesystem as available, or not
|
void |
setConfigurationParameters(org.springframework.extensions.config.ConfigElement params)
Set the configuration parameters
|
void |
setDeviceName(String name)
Set the device name.
|
void |
setShareName(String shareName)
Set the shared device name
|
String |
toString()
Return the context as a string
|
public DeviceContext()
public DeviceContext(String devName)
devName
- Stringpublic final String getDeviceName()
public final String getShareName()
public final boolean hasConfigurationParameters()
public final boolean isAvailable()
public final org.springframework.extensions.config.ConfigElement getConfigurationParameters()
public final void setAvailable(boolean avail)
avail
- booleanpublic final void setDeviceName(String name)
name
- java.lang.Stringpublic final void setShareName(String shareName)
shareName
- Stringpublic final void setConfigurationParameters(org.springframework.extensions.config.ConfigElement params)
params
- ConfigElementpublic void CloseContext()
Copyright © 2005–2017 Alfresco Software. All rights reserved.