sk.robotics.rlcs.agents.os
Class FileLoaderAgent.Cfg

java.lang.Object
  extended by sk.robotics.rlcs.agentspace.Agent.Cfg
      extended by sk.robotics.rlcs.agents.os.FileLoaderAgent.Cfg
Enclosing class:
FileLoaderAgent

public static class FileLoaderAgent.Cfg
extends Agent.Cfg


Nested Class Summary
static class FileLoaderAgent.Cfg.FileType
           
 
Nested classes/interfaces inherited from class sk.robotics.rlcs.agentspace.Agent.Cfg
Agent.Cfg.Limited, Agent.Cfg.NoDefault, Agent.Cfg.Required, Agent.Cfg.Validator
 
Field Summary
 java.lang.String blockContent
          Name of block where to store content of the file.
 java.lang.String charset
          Character encoding used in the file.
 FileLoaderAgent.Cfg.FileType fileType
          File type, Binary or text.
 java.lang.Boolean loadOnlyModified
          Reload the file only if it was modified since last time.
 java.lang.String path
          Path to the file to load.
 
Fields inherited from class sk.robotics.rlcs.agentspace.Agent.Cfg
enabled, id, logLevel, timerPeriodMs, triggers
 
Constructor Summary
FileLoaderAgent.Cfg()
           
 
Method Summary
 void validate()
          Config validation.
 
Methods inherited from class sk.robotics.rlcs.agentspace.Agent.Cfg
createAgent, equals, getHiddenFields, hideFields
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

path

public java.lang.String path
Path to the file to load.


fileType

public FileLoaderAgent.Cfg.FileType fileType
File type, Binary or text. Specifies type of data to store in space: string or byte array.


charset

public java.lang.String charset
Character encoding used in the file. Applicable obly for text files, ignored for binary files. If not specified for a text file, a system-default charset is used.


loadOnlyModified

public java.lang.Boolean loadOnlyModified
Reload the file only if it was modified since last time.


blockContent

public java.lang.String blockContent
Name of block where to store content of the file. A string is stored there for text files, an array of bytes for for binary files.

Block access:
write
Stored type:
String/byte[]
Constructor Detail

FileLoaderAgent.Cfg

public FileLoaderAgent.Cfg()
Method Detail

validate

public void validate()
Description copied from class: Agent.Cfg
Config validation. This base versions checks that fields declared as required (through the Required annotation) are filled. Derived agent config classes may override this to provide custom validation function for user defined configuration. It can be as well used for setting default values for uninitialized fields, or any other processing. To veto launching the agent, it can throw an exception.

Overrides:
validate in class Agent.Cfg