pySROS modules
pysros- Model-driven SR OS interfacepysros.management- Connection and data handlingpysros.pprint- Specialized output formattingpysros.wrappers- Model-driven class wrapperspysros.exceptions- pySROS specific exceptionspysros.ehs- Functions for the event handling system (EHS)pysros.ehs.get_event()pysros.ehs.Eventpysros.ehs.Event.namepysros.ehs.Event.appidpysros.ehs.Event.eventidpysros.ehs.Event.severitypysros.ehs.Event.sequencepysros.ehs.Event.subjectpysros.ehs.Event.router_namepysros.ehs.Event.gentimepysros.ehs.Event.timestamppysros.ehs.Event.textpysros.ehs.Event.eventparameterspysros.ehs.Event.format_msg()
pysros.ehs.EventParams
pysros.esm- Functions for the enhanced subscriber management system (ESM)pysros.esm.cryptolib- Cryptographic functions for the ESM systempysros.syslog- Functions for syslog event handlingpysros.syslog.get_event()generate_pri()severity_to_name()get_system_name()pysros.syslog.Eventpysros.syslog.Event.namepysros.syslog.Event.appidpysros.syslog.Event.eventidpysros.syslog.Event.severitypysros.syslog.Event.sequencepysros.syslog.Event.subjectpysros.syslog.Event.router_namepysros.syslog.Event.gentimepysros.syslog.Event.timestamppysros.syslog.Event.hostnamepysros.syslog.Event.log_prefixpysros.syslog.Event.facilitypysros.syslog.Event.textpysros.syslog.Event.eventparameterspysros.syslog.Event.format_msg()pysros.syslog.Event.format_syslog_msg()pysros.syslog.Event.override_payload()pysros.syslog.Event.drop()
pysros.syslog.EventParamspysros.syslog.Facilitypysros.syslog.Facility.KERNELpysros.syslog.Facility.USERpysros.syslog.Facility.MAILpysros.syslog.Facility.SYSTEMDpysros.syslog.Facility.AUTHpysros.syslog.Facility.SYSLOGDpysros.syslog.Facility.PRINTERpysros.syslog.Facility.NETNEWSpysros.syslog.Facility.UUCPpysros.syslog.Facility.CRONpysros.syslog.Facility.AUTHPRIVpysros.syslog.Facility.FTPpysros.syslog.Facility.NTPpysros.syslog.Facility.LOGAUDITpysros.syslog.Facility.LOGALERTpysros.syslog.Facility.CRON2pysros.syslog.Facility.LOCAL0pysros.syslog.Facility.LOCAL1pysros.syslog.Facility.LOCAL2pysros.syslog.Facility.LOCAL3pysros.syslog.Facility.LOCAL4pysros.syslog.Facility.LOCAL5pysros.syslog.Facility.LOCAL6pysros.syslog.Facility.LOCAL7
Libraries adapted for SR OS
The adapted versions of the modules documented here are provided when executing on SR OS only. When executing on a remote device, the native Python versions of the library are used.
argparse– Argument parser functions- Core Functionality
- Quick Links for add_argument()
- Example
- ArgumentParser objects
- The add_argument() method
- The parse_args() method
- Other utilities
- Exceptions
utime– Time functionsuio– Input/Output stream functions- Returned object types
- Functions
- Classes
TextIOTextIO.read()TextIO.readinto()TextIO.write()TextIO.seek()TextIO.tell()TextIO.flush()TextIO.close()TextIO.writelines()TextIO.readline()TextIO.readlines()TextIO.readable()TextIO.writable()TextIO.seekable()TextIO.truncate()TextIO.bufferedTextIO.closedTextIO.modeTextIO.nameTextIO.newlines
FileIOStringIOBytesIO
uos– Filesystem functionsuos.path– Filesystem functionsgetpass— Portable password input