Package dev.metaschema.oscal.lib.model
Class SelectControlById
java.lang.Object
dev.metaschema.oscal.lib.model.SelectControlById
- All Implemented Interfaces:
dev.metaschema.core.model.IBoundObject
@MetaschemaAssembly(formalName="Select Control",
description="Select a control or controls from an imported control set.",
name="select-control-by-id",
moduleClass=OscalMappingCommonModule.class,
remarks="If `with-child-controls` is \"yes\" on the call to a control, no sibling `call`elements need to be used to call any controls appearing within it. Since generally, this is how control enhancements are represented (as controls within controls), this provides a way to include controls with all their dependent controls (enhancements) without having to call them individually.")
public class SelectControlById
extends Object
implements dev.metaschema.core.model.IBoundObject
Select a control or controls from an imported control set.
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs a newdev.metaschema.oscal.lib.model.SelectControlByIdinstance with no metadata.SelectControlById(dev.metaschema.core.model.IMetaschemaData data) Constructs a newdev.metaschema.oscal.lib.model.SelectControlByIdinstance with the specified metadata. -
Method Summary
Modifier and TypeMethodDescriptionbooleanAdd a newMappedControlMatchingitem to the underlying collection.booleanAdd a newStringitem to the underlying collection.Get the "Match Controls by Pattern".dev.metaschema.core.model.IMetaschemaDataGet the "Include Contained Controls with Control".Get the "Match Controls by Identifier".booleanRemove the first matchingMappedControlMatchingitem from the underlying collection.booleanremoveWithId(String item) Remove the first matchingStringitem from the underlying collection.voidsetMatching(List<MappedControlMatching> value) Set the "Match Controls by Pattern".voidsetWithChildControls(String value) Set the "Include Contained Controls with Control".voidsetWithIds(List<String> value) Set the "Match Controls by Identifier".toString()
-
Constructor Details
-
SelectControlById
public SelectControlById()Constructs a newdev.metaschema.oscal.lib.model.SelectControlByIdinstance with no metadata. -
SelectControlById
Constructs a newdev.metaschema.oscal.lib.model.SelectControlByIdinstance with the specified metadata.- Parameters:
data- the metaschema data, ornullif none
-
-
Method Details
-
getMetaschemaData
- Specified by:
getMetaschemaDatain interfacedev.metaschema.core.model.IBoundObject
-
getWithChildControls
Get the "Include Contained Controls with Control".When a control is included, whether its child (dependent) controls are also included.
- Returns:
- the with-child-controls value, or
nullif not set
-
setWithChildControls
Set the "Include Contained Controls with Control".When a control is included, whether its child (dependent) controls are also included.
- Parameters:
value- the with-child-controls value to set, ornullto clear
-
getWithIds
Get the "Match Controls by Identifier".Selecting a control by its ID given as a literal.
- Returns:
- the with-id value
-
setWithIds
Set the "Match Controls by Identifier".Selecting a control by its ID given as a literal.
- Parameters:
value- the with-id value to set
-
addWithId
Add a newStringitem to the underlying collection.- Parameters:
item- the item to add- Returns:
true
-
removeWithId
Remove the first matchingStringitem from the underlying collection.- Parameters:
item- the item to remove- Returns:
trueif the item was removed orfalseotherwise
-
getMatching
Get the "Match Controls by Pattern".Selecting a set of controls by matching their IDs with a wildcard pattern.
- Returns:
- the matching value
-
setMatching
Set the "Match Controls by Pattern".Selecting a set of controls by matching their IDs with a wildcard pattern.
- Parameters:
value- the matching value to set
-
addMatching
Add a newMappedControlMatchingitem to the underlying collection.- Parameters:
item- the item to add- Returns:
true
-
removeMatching
Remove the first matchingMappedControlMatchingitem from the underlying collection.- Parameters:
item- the item to remove- Returns:
trueif the item was removed orfalseotherwise
-
toString
-