Skip to main content

Crate xbrl_rs

Crate xbrl_rs 

Source
Expand description

Parser for XBRL documents with support for:

  • XBRL instance documents
  • XBRL taxonomy schemas
  • XBRL taxonomy linkbases (presentation, calculation, definition, label, reference)

Structs§

ArcroleType
A resolved link:arcroleType definition from a taxonomy schema.
ArcroleUri
Arc role URI used in presentation/calculation/definition maps (e.g. http://www.xbrl.org/2003/arcrole/parent-child).
CalculationArc
A resolved calculation arc between two concepts.
Concept
An XBRL concept defined in the taxonomy schema.
ConceptId
Concept element identifier used in label/reference maps (e.g. de-gaap-ci_bs.ass).
ConceptView
A focused view of a single concept and its relationships.
Context
XBRL context combining entity, period, and optional dimensions
ContextId
Type-safe identifier for an XBRL context (the id attribute on <xbrli:context> elements).
DeclaredAccuracy
Declared accuracy constraints for an XBRL item type.
DefinitionArc
A resolved definition arc between two concepts.
DocumentView
A hierarchical view of an XBRL document organised by presentation sections.
ElementDecl
Represents an element declaration in the schema, which can be either a global element or an inline element declaration inside a compositor.
EntityIdentifier
Identifies the reporting entity
ExpandedName
The element’s resolved name, based on unique namespace uri instead of prefix.
FootnoteArc
An arc in a footnote link (for example link:footnoteArc).
FootnoteLink
A single link:footnoteLink extended link in an XBRL instance.
FootnoteLocator
A locator within a footnote link, usually a link:loc element.
FootnoteResource
A footnote resource within a footnote link (link:footnote).
GroupDef
Represents a group definition in a complex type’s content model.
InstanceDocument
Represents a complete XBRL instance document
InstanceParser
The parser for XBRL instance documents.
InstanceWriter
The writer for XBRL instance documents.
ItemFact
Represents a single item fact (data point) in an XBRL instance.
Label
A human-readable label for a taxonomy concept.
LinkbaseLocator
A locator extracted from a linkbase <loc> element.
LinkbaseParser
The parser for XBRL linkbase documents.
NamespacePrefix
Type-safe namespace prefix key (e.g. xmlns:xbrli declaration on the root <xbrli:xbrl> element).
NamespaceUri
Type-safe namespace URI key (e.g. xmlns:xbrli=“http://www.xbrl.org/2003/instance” declarations on the root <xbrli:xbrl> element).
Occurrence
Represents the occurence constraints for a particle in a complex type’s content model.
PresentationArc
A resolved presentation arc between two concepts.
PresentationRelationView
A presentation relationship from or to a concept in a given role.
QName
Represents a qualified name in the XML document (e.g., “xbrli:monetaryItemType”).
Reference
A regulatory/legal reference for a taxonomy concept.
ReferencePart
A single key-value part within a reference.
RoleType
A resolved link:roleType definition from a taxonomy schema.
RoleUri
Extended link role URI used in presentation/calculation/definition maps (e.g. http://www.xbrl.de/taxonomies/de-gaap-ci/role/balanceSheet or http://www.xbrl.org/2003/role/label).
SchemaParser
The parser for XBRL schema documents.
SchemaRefUrl
Identifier for schema ref urls (e.g. http://www.xbrl.de/taxonomies/de-gcd-2020-04-01/de-gcd-2020-04-01-shell.xsd).
SectionView
One report section (extended link role) from the presentation linkbase.
SubstitutionGroup
The resolved substitution group of a concept, including both the resolved base group and the original QName.
TaxonomySchema
A parsed taxonomy schema (.xsd) file.
TaxonomySectionView
One presentation role section in a taxonomy view.
TaxonomySet
The complete Discoverable Taxonomy Set (DTS).
TaxonomyTreeNode
A concept node in a taxonomy presentation tree.
TaxonomyView
A hierarchical view of taxonomy concepts organized by presentation role.
TreeNode
A single node in the presentation hierarchy.
TupleElementView
A tuple element projection.
TupleFact
Represents a tuple fact that can contain child facts.
TypedInstanceDocument
A typed representation of an XBRL instance document.
TypedItemFact
TypedTupleFact
Unit
Represents a unit of measurement
UnitId
Type-safe identifier for an XBRL unit (the id attribute on <xbrli:unit> elements).
ValidationMessage
A single validation finding.
ValidationResult
Collected results of validating an instance document.
XmlReader
A low level encoding-agnostic XML event reader.
XmlWriter
XML writer. Writes XML Events to a std::io::Write implementor.

Enums§

Balance
The XBRL balance type for a monetary taxonomy element (xbrli:balance attribute).
BaseSubstitutionGroup
The base substitution group of a concept, resolved to either Item or Tuple.
Decimals
The numeric accuracy attribute value for a fact (decimals or precision).
ElementParticle
Represents an element particle in a complex type’s content model.
Fact
Represents a single fact (data point) in an XBRL instance
FactAttribute
Supported mutable attributes for item facts.
FactAttributeName
Names of removable item-fact attributes.
FactValue
GroupParticle
Represents a group particle in a complex type’s content model.
LinkbaseType
The type of linkbase being parsed
Particle
Represents a particle in a complex type’s content model.
Period
Time period for a context (instant or duration)
PeriodType
The XBRL period type for a taxonomy element (xbrli:periodType attribute).
Severity
Severity level of a validation message.
TupleParticleView
A projected tuple content-model particle for display.
TypedFact
Represents a typed fact in the instance, which can be either an item or a tuple.
ValueError
Error type for typed fact value conversion.
XbrlError
Error type for XBRL operations
XbrlType
Standard XBRL base types (from xbrli) and common custom types (e.g., shares, percent).

Constants§

ROLE_LABEL
ROLE_TERSE

Functions§

resolve_instance
Resolve a [RawInstance] into an InstanceDocument.

Type Aliases§

Result
Result type alias for XBRL operations