public class RepositoryIO extends EventObject
InputStream or OutputStream
instances provided by a RepositoryDriver instance to read or store a compiled
MIB module from/into persistent storage. In addition, it can indicate that a MIB module
should be removed from the MIB repository.source| Constructor and Description |
|---|
RepositoryIO(Object source,
String moduleName)
Creates an
RepositoryEvent to load or store a given MIB module. |
| Modifier and Type | Method and Description |
|---|---|
InputStream |
getInputStream()
Gets the input stream to be used to load a compiled MIB module from
persistent storage.
|
String |
getModuleName()
Gets the module name of the MIB module to read or write.
|
OutputStream |
getOutputStream()
Gets the output stream to write the MIB module.
|
boolean |
isModuleDeleted()
Indicates whether the deletion of the MIB module specified by the module
name of this event object was successfully completed.
|
void |
setInputStream(InputStream inputStream)
Sets the
InputStream to be used to load a compiled MIB
module from persistent storage. |
void |
setModuleDeleted(boolean moduleDeleted)
Sets the flag that indicates whether a MIB module has been successfully
removed from persistent storage.
|
void |
setOutputStream(OutputStream outputStream)
Sets the output stream to write a MIB module with the given name to the
repository.
|
getSource, toStringpublic InputStream getInputStream()
InputStream.public void setInputStream(InputStream inputStream)
InputStream to be used to load a compiled MIB
module from persistent storage. The input stream must be set when a
RepositoryDriver.readModule(com.snmp4j.smi.RepositoryIO) event is processed.inputStream - an InputStream that reads the MIB module with the name
specified by getModuleName().public void setOutputStream(OutputStream outputStream)
RepositoryDriver.writeModule(com.snmp4j.smi.RepositoryIO) event is received.outputStream - an OutputStream instance.public OutputStream getOutputStream()
OutputStream instance.public String getModuleName()
public void setModuleDeleted(boolean moduleDeleted)
RepositoryDriver interface receives a request to delete
a MIB module.moduleDeleted - a boolean value that indicates whether the MIB module has been deleted.public boolean isModuleDeleted()
true if the MIB module was removed from persistent storage.Copyright © 2015 SNMP4J.com. All Rights Reserved.