2. acg
- class fwOper.acg.OBJ(obj_grp_name, _hash)[source]
Bases:
fwOper.fwObj.Singulars
Individual group object
- Parameters
Singulars (Singulars) – Inherits - individual object properties definitions
- Raises
Exception – IncorrectIteminItemType
Exception – InvalidGroupMemberType
Exception – NoValidCandidate
- Returns
a single object-group object
- Return type
- property grp_details
object group details in dictionary (helpful in generating copy)
- Returns
object-group primary/basic details
- Return type
dict
- over(acls)[source]
returns dictionary of acls with acl/line/attribute if object group present in any acls
- Parameters
acls (ACLS) – dictionary of all acls (ACLS)
- Returns
dictionary of acls with acl/line/attribute
- Return type
dict
- parse()[source]
starts parsing object-group-config-lines-list and set extended variables of instance
- class fwOper.acg.OBJS(config_list)[source]
Bases:
fwOper.fwObj.Plurals
collection of object groups
- Parameters
Plurals (Plurals) – Inherits - group of items properties definitions
- changes(change)[source]
collate the delta changes recorded in all object-groups and provide delta for that change ( “ADDS”, “REMOVALS”)
- Parameters
change (str) – type of change for which change output requested ( “ADDS”, “REMOVALS” )
- Returns
delta changes
- Return type
str
- get_matching_obj_grps(requests)[source]
matches provided (request members) in all object-groups available on device and returns dictionary of object-group names, where object-group matches same members in it.
- Parameters
requests (tuple, list, set) – list/set/tuple with members of dict, containing ‘source’, ‘destination’, ‘ports’ as keys.
- Raises
Exception – Invalid Request type
- Returns
include all three, src, dest, port
- Return type
dict