xbrl.Item¶
An xbrl.Item class represents an item in an XBRL instance document.
Base class: xbrl.Fact
- 
class xbrl.Item¶
- Proper instances of this class will be created within RaptorXML only, instantiation from script code will throw a - NotImplementedErrorexception.
Attributes¶
- 
xbrl.Item.actual_type_definition¶
- Returns an xsd.SimpleTypeDefintion object which represents the actual simple type definition that was used to validate the value of this XBRL fact. In case of types derived from xbrli:dateTimeItemType, one of the union member types xs:date or xs:dateTime will be returned. Returns None if the XBRL fact is of type xbrli:fractionItemType. 
- 
xbrl.Fact.aspect_values
- Returns an - xbrl.ConstraintSetobject with aspect values of the XBRL fact for all aspects in the dimensional aspect model.
- 
xbrl.Item.boolean_value¶
- Returns the boolean value as bool. Returns None if the xsi:nil attribute is set to True. Raises an - AttributeErrorif the XBRL fact is not a boolean item.
- 
xbrl.Fact.concept
- Returns an - xbrl.taxonomy.Conceptobject which represents the XBRL concept associated with this XBRL fact.
- 
xbrl.Fact.concept_aspect_value
- Returns an - xbrl.ConceptAspectValueobject which represents the concept aspect value of the XBRL fact.
- 
xbrl.Item.context¶
- Returns an - xbrl.Contextobject which represents the XBRL context referenced by this XBRL item.
- 
xbrl.Fact.contextRef
- Returns the value of the ‘contextRef’ attribute as a string, or None if the XML element information item doesn’t have a ‘contextRef’ attribute. 
- 
xbrl.Item.decimals¶
- Returns the value of the ‘decimals’ attribute as an int, or None if the XML element information item doesn’t have a ‘decimals’ attribute. If the decimals attribute value is ‘INF’, float(‘inf’) is returned. 
- 
xbrl.Item.dimension_aspect_values¶
- Returns an iterator of - xbrl.ExplicitDimensionAspectValueand- xbrl.TypedDimensionAspectValueobjects representing the dimension aspect values of the XBRL fact.
- 
xbrl.Item.effective_fraction_value¶
- [Deprecated: use fraction_value instead!] Returns the effective fraction value as fractions.Fraction. Returns None if the xsi:nil attribute is set to True. Raises an - AttributeErrorif the XBRL fact is not a numeric item of type fractionItemType or a type derived from fractionItemType by restriction.
- 
xbrl.Item.effective_numeric_value¶
- Returns the effective numeric value after rounding as decimal.Decimal. Returns None if the xsi:nil attribute is set to True. Raises an - AttributeErrorif the XBRL fact is not a numeric item.
- 
xbrl.Fact.element
- Returns an - xml.ElementInformationItemobject which represents the XML element information item of the XBRL fact.
- 
xbrl.Item.entity_identifier_aspect_value¶
- Returns an - xbrl.EntityIdentifierAspectValueobject which represents the entity identifier aspect value of the XBRL fact.
- 
xbrl.Item.enum_value¶
- Returns an - xbrl.taxonomy.Itemobject which represents the enumeration value of this XBRL fact. Returns None if the xsi:nil attribute is set to True. Raises an- AttributeErrorif the XBRL item is not a single value enumeration concept.
- 
xbrl.Item.enum_values¶
- Returns an iterator of - xbrl.taxonomy.Itemobjects which represent the enumeration values of this XBRL fact. Raises an- AttributeErrorif the XBRL item is not a set value enumeration concept.
- 
xbrl.Item.explicit_dimension_aspect_values¶
- Returns an iterator of - xbrl.ExplicitDimensionAspectValueobjects representing the explicit dimension aspect values of the XBRL fact.
- 
xbrl.Item.fraction_value¶
- Returns the effective fraction value as fractions.Fraction. Returns None if the xsi:nil attribute is set to True. Raises an - AttributeErrorif the XBRL fact is not a numeric item of type fractionItemType or a type derived from fractionItemType by restriction.
- 
xbrl.Fact.id
- Returns the value of the ‘id’ attribute as a string, or None if the XML element information item doesn’t have an ‘id’ attribute. 
- 
xbrl.Item.inferred_decimals¶
- Returns the inferred decimals value according to http://www.xbrl.org/Specification/XBRL-2.1/REC-2003-12-31/XBRL-2.1-REC-2003-12-31+corrected-errata-2013-02-20.html#_4.6.6 as an int or float(‘inf’). If the precision attribute on the XBRL fact was 0, the decimals value cannot be inferred and float(‘nan’) is returned. Raises an - AttributeErrorif the XBRL fact is not a numeric item.
- 
xbrl.Item.inline_display_value¶
- Returns the display value associated with the fact in an inline xbrl document. 
- 
xbrl.Item.inline_format¶
- Returns the format qname associated with the fact in an inline xbrl document. 
- 
xbrl.Fact.inline_is_hidden
- Returns a boolean if the fact is hidden in an inline document. 
- 
xbrl.Item.inline_negated¶
- Returns a boolean if the fact has a sign in an inline document. 
- 
xbrl.Item.inline_scale¶
- Returns the scale of a fact in an inline xbrl document. 
- 
xbrl.Fact.instance
- Returns an - xbrl.Instanceobject which represents the containing XBRL instance document.
- 
xbrl.Fact.location_aspect_value
- Returns an - xbrl.LocationAspectValueobject which represents the location aspect value of the XBRL fact.
- 
xbrl.Item.non_xdt_scenario_aspect_value¶
- Returns an - xbrl.ScenarioAspectValueobject which represents the non-xdt scenario aspect value of the XBRL fact.
- 
xbrl.Item.non_xdt_segment_aspect_value¶
- Returns an - xbrl.SegmentAspectValueobject which represents the non-xdt segment aspect value of the XBRL fact.
- 
xbrl.Item.normalized_value¶
- Returns the schema normalized value of the XBRL fact as a string. Returns None if the xsi:nil attribute is set to True. Raises an - AttributeErrorif the XBRL fact is a numeric item of type fractionItemType.
- 
xbrl.Item.numeric_value¶
- Returns the numeric value before rounding as decimal.Decimal. Returns None if the xsi:nil attribute is set to True. Raises an - AttributeErrorif the XBRL fact is not a numeric item.
- 
xbrl.Fact.parent
- Returns an - xbrl.Tupleobject if the fact is contained within a tuple or an- xbrl.Instanceobject if the fact is at the top level (contained in <xbrli:xbrl>).
- 
xbrl.Item.period_aspect_value¶
- Returns an - xbrl.PeriodAspectValueobject which represents the period aspect value of the XBRL fact.
- 
xbrl.Item.precision¶
- Returns the value of the ‘precision’ attribute as an int, or None if the XML element information item doesn’t have a ‘precision’ attribute. If the precision attribute value is ‘INF’, float(‘inf’) is returned. 
- 
xbrl.Fact.qname
- Returns an - xml.QNameobject which represents the XML qualified name of the XBRL fact element information item.
- 
xbrl.Item.qname_value¶
- Returns an - xml.QNameobject which represents the QName value of this XBRL fact. Returns None if the xsi:nil attribute is set to True. Raises an- AttributeErrorif the XBRL fact is not of type xbrli:QNameItemType.
- 
xbrl.Item.typed_dimension_aspect_values¶
- Returns an iterator of - xbrl.TypedDimensionAspectValueobjects representing the typed dimension aspect values of the XBRL fact.
- 
xbrl.Item.unit¶
- Returns an - xbrl.Unitobject which represents the XBRL unit referenced by this XBRL item.
- 
xbrl.Fact.unitRef
- Returns the value of the ‘unitRef’ attribute as a string, or None if the XML element information item doesn’t have an ‘unitRef’ attribute. 
- 
xbrl.Item.unit_aspect_value¶
- Returns an - xbrl.UnitAspectValueobject which represents the unit aspect value of the XBRL fact, or None if the XBRL fact doesn’t have an unit aspect.
- 
xbrl.Item.xml_lang¶
- Returns the value of the ‘xml:lang’ attribute as a string, or None if the XML element information item doesn’t have an ‘xml:lang’ attribute. 
- 
xbrl.Fact.xsi_nil
- Returns True if the XBRL fact’s element information item has the xsi:nil attribute set to True, otherwise False. 
Methods¶
- 
xbrl.Item.c_equal(Item fact)¶
- Returns true if both facts are C-Equal as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Item.cu_equal(Item fact)¶
- Returns true if both facts are C-Equal and U-Equal as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Item.dimension_aspect_value(Dimension dimension)¶
- Returns an - xbrl.ExplicitDimensionAspectValueor- xbrl.TypedDimensionAspectValueobject which represents the dimension aspect value of the XBRL fact, or None if the XBRL fact doesn’t have a dimension aspect for the given dimension.
- 
xbrl.Fact.duplicate(Fact fact, aspect_based=False)
- Returns true if both facts are duplicates as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Item.duplicate_class(Item fact)¶
- Returns an - xbrl.DuplicateClassenum specifying the type of duplicates.
- 
xbrl.Fact.footnote_relationships(arc_role=None, link_role=None)
- Returns an iterator of - xbrl.taxonomy.FootnoteRelationshipobjects. If called without any arguments, all <footnoteArc> relationships starting from this fact will be returned. Use arc_role and link_role arguments to constrain the returned relationships.
- 
xbrl.Fact.footnotes(footnote_role=None, arc_role=None, link_role=None, lang=None)
- Returns an iterator of - xbrl.taxonomy.Footnoteobjects. If called without any arguments, all assigned fact-footnote footnotes will be returned. Use foonote_role, arc_role, link_role and lang arguments to constrain the returned footnotes. If arc_role is not specified, only footnotes connected by fact-footnotes <footnoteArc> arcs are considered.
- 
xbrl.Fact.has_ancestor(Tuple tuple)
- Returns true if the give tuple is an ancestor of this fact. 
- 
xbrl.Fact.identical(Fact fact)
- Returns true if both facts are identical as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Fact.p_equal(Fact fact)
- Returns true if both facts are P-Equal as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Item.pcu_equal(Item fact)¶
- Returns true if both facts are P-Equal, C-Equal and U-Equal as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Item.round_numeric_value(decimals)¶
- Returns the numeric value after rounding to the given decimal places as decimal.Decimal. Returns None if the xsi:nil attribute is set to True. Raises an - AttributeErrorif the XBRL fact is not a numeric item.
- 
xbrl.Fact.s_equal(Fact fact)
- Returns true if both facts are S-Equal as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Item.u_equal(Item fact)¶
- Returns true if both facts are U-Equal as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Item.v_equal(Item fact)¶
- Returns true if both facts are V-Equal as defined by the XBRL 2.1 equality predicates. 
- 
xbrl.Fact.xpointer(force_element_scheme=False)
- Returns an URI with XPointer fragment that points to this XML element as a string. If the XML element information item has an id attribute, a shorthand pointer with the id attribute value will be generated, otherwise the XPointer element scheme will be used. Set force_element_scheme to True to prevent generation of shorthand pointers. 
Special methods¶
__bool__, __eq__, __ge__, __gt__, __le__, __lt__, __ne__
