openc2lib.profiles.slpf.args

SLPF Arguments

This module extends the Args defined by the Language Specification (see Sec. 2.1.3.2 of the SLPF Specification).

 1""" SLPF Arguments
 2	
 3	This module extends the Args defined by the Language Specification
 4	(see Sec. 2.1.3.2 of the SLPF Specification).
 5"""
 6import openc2lib as oc2
 7
 8import openc2lib.profiles.slpf.nsid as profile_name
 9from openc2lib.profiles.slpf.datatypes import DropProcess, Direction
10from openc2lib.profiles.slpf.targettypes import RuleID
11
12class Args(oc2.Args):
13	""" SLPF Args
14
15		This class extends the Args defined in the Language Specification.
16		The extension mechanism is described in the 
17		[Developing extensions](https://github.com/mattereppe/openc2lib/blob/main/docs/developingextensions.md#developing-extensions) Section of the main documentation.
18
19		Note that the same name is used as the base class, to make it simpler to 
20		remember. The recommended way to use in the code is to import the whole
21		slpf module as `slpf` and refer to this class as `slpf.Args`.
22
23	"""
24	extend = oc2.Args
25	""" The class to extend (`openc2lib.core.args.Args` defined in the core section). """
26	fieldtypes = oc2.Args.fieldtypes.copy()
27	""" Copy all `fieldtypes` defined in the base class. """
28	fieldtypes['drop_process']=DropProcess
29	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
30	fieldtypes['persistent']=bool
31	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
32	fieldtypes['direction']=Direction
33	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
34	fieldtypes['insert_rule']=RuleID
35	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
36	nsid = profile_name
37	""" Namespace identifier to distinguish extensions """
class Args(openc2lib.core.args.Args):
13class Args(oc2.Args):
14	""" SLPF Args
15
16		This class extends the Args defined in the Language Specification.
17		The extension mechanism is described in the 
18		[Developing extensions](https://github.com/mattereppe/openc2lib/blob/main/docs/developingextensions.md#developing-extensions) Section of the main documentation.
19
20		Note that the same name is used as the base class, to make it simpler to 
21		remember. The recommended way to use in the code is to import the whole
22		slpf module as `slpf` and refer to this class as `slpf.Args`.
23
24	"""
25	extend = oc2.Args
26	""" The class to extend (`openc2lib.core.args.Args` defined in the core section). """
27	fieldtypes = oc2.Args.fieldtypes.copy()
28	""" Copy all `fieldtypes` defined in the base class. """
29	fieldtypes['drop_process']=DropProcess
30	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
31	fieldtypes['persistent']=bool
32	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
33	fieldtypes['direction']=Direction
34	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
35	fieldtypes['insert_rule']=RuleID
36	""" Extension with SLPF specific arguments (Sec. 2.1.3.2 of the SLPF Specification) """
37	nsid = profile_name
38	""" Namespace identifier to distinguish extensions """

SLPF Args

This class extends the Args defined in the Language Specification. The extension mechanism is described in the Developing extensions Section of the main documentation.

Note that the same name is used as the base class, to make it simpler to remember. The recommended way to use in the code is to import the whole slpf module as slpf and refer to this class as slpf.Args.

extend = <class 'openc2lib.core.args.Args'>

The class to extend (openc2lib.core.args.Args defined in the core section).

fieldtypes = {'start_time': <class 'openc2lib.types.datatypes.DateTime'>, 'stop_time': <class 'openc2lib.types.datatypes.DateTime'>, 'duration': <class 'openc2lib.types.datatypes.Duration'>, 'response_requested': <aenum 'ResponseType'>, 'drop_process': <aenum 'DropProcess'>, 'persistent': <class 'bool'>, 'direction': <aenum 'Direction'>, 'insert_rule': <class 'openc2lib.profiles.slpf.targettypes.RuleID'>}

Copy all fieldtypes defined in the base class.

nsid = 'slpf'

Namespace identifier to distinguish extensions

Inherited Members
openc2lib.core.args.Args
regext
openc2lib.types.basetypes.Map
todict
fromdict
builtins.dict
get
setdefault
pop
popitem
keys
items
values
update
fromkeys
clear
copy