Function-Base

Base class for for SECS stream and functions.

class secsgem.secs.functions.base.StructureDisplayingMeta[source]

Meta class overriding the default __repr__ of a class.

class secsgem.secs.functions.base.SecsStreamFunction(value=None)[source]

Secs stream and function base class.

This class is inherited to create a stream/function class. To create a function specific content the class variables _stream, _function and _data_format must be overridden.

append(data)[source]

Append data to list, if stream/function parameter is a list.

Parameters:

data – list item to add

encode()[source]

Generate the encoded hsms data of the stream/function parameter.

Return type:

bytes

Returns:

encoded data

decode(data)[source]

Update stream/function parameter data from the passed data.

Parameters:

data – encoded data

set(value)[source]

Update the value of the stream/function parameter.

Parameters:

value – new value for the parameter

get()[source]

Get the current value of the stream/function parameter.

Returns:

current parameter value

classmethod get_format()[source]

Get the format of the function.

Returns:

string representation of the function