xbrl.ConstraintSet
¶
The ConstraintSet class represents a set of constraints for the aspects in the dimensional aspect model. For each aspect, zero or one aspect can be specified.
-
class
xbrl.
ConstraintSet
(context=None)¶ Creates a new empty
xbrl.ConstraintSet
object. It takes anxbrl.DTS
orxbrl.Instance
object as as a parameter.
Attributes¶
-
xbrl.ConstraintSet.
allow_additional_dimensions
¶ Read/write of type Boolean value. If set to false, restricts the facts returned by Instance.select_facts() and FactSet.filter() methods to contain only facts whose assigned contexts don’t contain any additional dimensions.
-
xbrl.ConstraintSet.
concept_aspect
¶ Returns an
xbrl.ConceptAspectValue
object representing the constraint for the concept aspect, or None if no constraint was specified. Is also writable.
-
xbrl.ConstraintSet.
dimension_aspects
¶ Returns a generator object of
xbrl.ExplicitDimensionAspectValue
andxbrl.TypedDimensionAspectValue
objects representing the constraints for the dimension aspect.
-
xbrl.ConstraintSet.
entity_identifier_aspect
¶ Returns an
xbrl.EntityIdentifierAspectValue
object representing the constraint for the entity identifier aspect, or None if no constraint was specified. Is also writable.
-
xbrl.ConstraintSet.
period_aspect
¶ Returns an
xbrl.PeriodAspectValue
object representing the constraint for the period aspect, or None if no constraint was specified. Is also writable.
-
xbrl.ConstraintSet.
scenario_aspect
¶ Returns an
xbrl.ScenarioAspectValue
object representing the constraint for the non-XDT scenario aspect, or None if no constraint was specified. Is also writable.
-
xbrl.ConstraintSet.
segment_aspect
¶ Returns an
xbrl.SegmentAspectValue
object representing the constraint for the non-XDT segment aspect, or None if no constraint was specified. Is also writable.
-
xbrl.ConstraintSet.
unit_aspect
¶ Returns an
xbrl.UnitAspectValue
object representing the constraint for the unit aspect, or None if no constraint was specified. Is also writable.
Methods¶
-
xbrl.ConstraintSet.
append
(aspect)¶ Adds a new constraint. Any existing constraint for this aspect will be overwritten.
-
xbrl.ConstraintSet.
clear
()¶ Removes any constraints for all aspects.
-
xbrl.ConstraintSet.
copy
()¶ Returns a new
xbrl.ConstraintSet
object containing the same constraints.
-
xbrl.ConstraintSet.
dimension_aspect
(dimension)¶ Returns an
xbrl.ExplicitDimensionAspectValue
orxbrl.TypedDimensionAspectValue
object for the given dimension aspect, or None if no constraint was specified.
-
xbrl.ConstraintSet.
extend
(constraintset)¶ Adds all the constraints from
xbrl.ConstraintSet
constraint-set. Any existing constraints will be overwritten.
-
xbrl.ConstraintSet.
set_dimension_aspect
(aspect)¶ Sets a constraint for the dimension aspect. Any existing constraint for this aspect will be overwritten.
Special methods¶
__eq__, __ge__, __gt__, __le__, __lt__, __ne__