com.ihr.xbrl.om.instance
Class XBRLFactsListImpl

java.lang.Object
  extended by com.ihr.xbrl.om.instance.XBRLFactsListImpl
All Implemented Interfaces:
XBRLFactsList, XMLHasParent

public class XBRLFactsListImpl
extends java.lang.Object
implements XBRLFactsList

Implementation of the XBRLFactsList interface in a class that can hold a list of facts but is not a fact itself and does not have any representation in XML nodes.

Author:
Ignacio

Constructor Summary
XBRLFactsListImpl(DTSContainer dts)
           
 
Method Summary
 void add(int index, XBRLFact fact)
          Resets the nillable status to false automatically.
 boolean add(XBRLFact fact)
          Resets the nillable status to false automatically.
 void addOrForwardItem(XBRLFactItem item)
          Called internally to register new facts in the instance document
 void addXMLChild(XMLHasParent child)
           
 void clear()
          Removes all children elements in this XBRLFactList
 XBRLFactsListImpl clone()
           
 XBRLFactsListImpl clone(DTSContainer newDTS)
           
 boolean equals(java.lang.Object obj)
          This function should be implemented by sub classes in order to properly implement
 net.sf.saxon.s9api.XdmValue evaluateList(java.lang.String string)
          Access to the surrounding method in the XMLFragment
 void forwardItem(XBRLFactItem item)
           
 XBRLFact get(int index)
          Returns the element at the selected index position.
 java.net.URI getBase()
           
 DTSContainer getContainer()
          Access to the surrounding container object
 net.sf.saxon.s9api.XdmNode getDocument()
          Access to the surrounding XdmDocument from the XMLFragment
 XBRLInstance getInstance()
          Access to the instance document on the top of this facts container hierarchy
 java.util.Iterator<java.util.Vector<XBRLFactItem>> getItems()
          Iterator over the items on this facts container
 java.util.Iterator<XBRLFactItem> getItems(XBRLItem itemFrom)
          Iterator over fact items that are instances of the XBRLItem received as a parameter.
 java.util.Iterator<XBRLFactItem> getItemsSg(XBRLItem itemFrom)
          Iterator over fact items that are instances of the XBRLItem received as a parameter of in the substitution group of that item
 int getNumberOfTuples()
          Calculates and returns the number of tuples children of this facts container
 XBRLFactsList getParent()
          Access to the parent document, Instance or tuple
 java.util.Iterator<java.util.Vector<XBRLFactTuple>> getTuples()
          Iterator over the tuples on this facts container
 java.util.Iterator<XBRLFactTuple> getTuples(XBRLTuple tupleFrom)
          Iterator over fact tuples that are instances of the XBRLTuple received as a parameter.
 java.util.Iterator<XBRLFactTuple> getTuplesSg(XBRLTuple tupleFrom)
          Iterator over fact tuples that are instances of the XBRLTuple received as a parameter of in the substitution group of that tuple
 java.lang.String getXPathToRoot()
          Access to the surrounding method from the XMLFragment
 int hashCode()
          This is from the Object interface and must be implemented by sub classes in order to be able to provide hashCodes
 int indexOf(XBRLFact fact)
          Returns the index position of a fact within this list
 int indexOf(XBRLFact fact, int index)
          Returns the index position of a fact within this list starting at the position indicated by the index parameter
 java.util.Iterator<XBRLFact> iterator()
           
 boolean remove(XBRLFact fact)
          Removes a fact from the facts container
 void removeXMLChild(XMLHasParent child)
           
 void setParent(XBRLFactsList parent)
          Sets the parent of this facts container to a new parent.
 void setParent(XMLHasParent parent)
           
 int size()
          Access to the number of elements in the XBRLFactList
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XBRLFactsListImpl

public XBRLFactsListImpl(DTSContainer dts)
Method Detail

clone

public XBRLFactsListImpl clone()
Overrides:
clone in class java.lang.Object

clone

public XBRLFactsListImpl clone(DTSContainer newDTS)

forwardItem

public void forwardItem(XBRLFactItem item)

add

public boolean add(XBRLFact fact)
Resets the nillable status to false automatically. Then calls the super implementation

Specified by:
add in interface XBRLFactsList

add

public void add(int index,
                XBRLFact fact)
Resets the nillable status to false automatically. Then calls the super implementation

Specified by:
add in interface XBRLFactsList

getItems

public java.util.Iterator<java.util.Vector<XBRLFactItem>> getItems()
Description copied from interface: XBRLFactsList
Iterator over the items on this facts container

Specified by:
getItems in interface XBRLFactsList
Returns:
Iterator<Vector<XBRLFactItem>>

getItems

public java.util.Iterator<XBRLFactItem> getItems(XBRLItem itemFrom)
Description copied from interface: XBRLFactsList
Iterator over fact items that are instances of the XBRLItem received as a parameter.

Specified by:
getItems in interface XBRLFactsList
Parameters:
itemFrom - XBRLItem
Returns:
Iterator<XBRLFactItem>

getTuples

public java.util.Iterator<java.util.Vector<XBRLFactTuple>> getTuples()
Description copied from interface: XBRLFactsList
Iterator over the tuples on this facts container

Specified by:
getTuples in interface XBRLFactsList
Returns:
Iterator<Vector<XBRLFactTuple>>

getTuples

public java.util.Iterator<XBRLFactTuple> getTuples(XBRLTuple tupleFrom)
Description copied from interface: XBRLFactsList
Iterator over fact tuples that are instances of the XBRLTuple received as a parameter.

Specified by:
getTuples in interface XBRLFactsList
Parameters:
tupleFrom - XBRLTuple
Returns:
Iterator<XBRLFactTuple>

getItemsSg

public java.util.Iterator<XBRLFactItem> getItemsSg(XBRLItem itemFrom)
Description copied from interface: XBRLFactsList
Iterator over fact items that are instances of the XBRLItem received as a parameter of in the substitution group of that item

Specified by:
getItemsSg in interface XBRLFactsList
Parameters:
itemFrom - XBRLItem
Returns:
Iterator<XBRLFactItem>

getTuplesSg

public java.util.Iterator<XBRLFactTuple> getTuplesSg(XBRLTuple tupleFrom)
Description copied from interface: XBRLFactsList
Iterator over fact tuples that are instances of the XBRLTuple received as a parameter of in the substitution group of that tuple

Specified by:
getTuplesSg in interface XBRLFactsList
Returns:
Iterator<XBRLFactTuple>

getNumberOfTuples

public int getNumberOfTuples()
Description copied from interface: XBRLFactsList
Calculates and returns the number of tuples children of this facts container

Specified by:
getNumberOfTuples in interface XBRLFactsList
Returns:
integer value

iterator

public java.util.Iterator<XBRLFact> iterator()
Specified by:
iterator in interface XBRLFactsList

remove

public boolean remove(XBRLFact fact)
Description copied from interface: XBRLFactsList
Removes a fact from the facts container

Specified by:
remove in interface XBRLFactsList
Returns:
boolean

setParent

public void setParent(XBRLFactsList parent)
Description copied from interface: XBRLFactsList
Sets the parent of this facts container to a new parent.

Specified by:
setParent in interface XBRLFactsList

addOrForwardItem

public void addOrForwardItem(XBRLFactItem item)
Description copied from interface: XBRLFactsList
Called internally to register new facts in the instance document

Specified by:
addOrForwardItem in interface XBRLFactsList

size

public int size()
Description copied from interface: XBRLFactsList
Access to the number of elements in the XBRLFactList

Specified by:
size in interface XBRLFactsList
Returns:
integer

get

public XBRLFact get(int index)
Description copied from interface: XBRLFactsList
Returns the element at the selected index position. The first element is at position 0

Specified by:
get in interface XBRLFactsList
Parameters:
index - integer
Returns:
XBRLFact at position indicated by index parameter

indexOf

public int indexOf(XBRLFact fact)
Description copied from interface: XBRLFactsList
Returns the index position of a fact within this list

Specified by:
indexOf in interface XBRLFactsList
Parameters:
fact - XBRLFact
Returns:
integer

indexOf

public int indexOf(XBRLFact fact,
                   int index)
Description copied from interface: XBRLFactsList
Returns the index position of a fact within this list starting at the position indicated by the index parameter

Specified by:
indexOf in interface XBRLFactsList
Parameters:
fact - XBRLFact
index - integer
Returns:
integer

clear

public void clear()
Description copied from interface: XBRLFactsList
Removes all children elements in this XBRLFactList

Specified by:
clear in interface XBRLFactsList

hashCode

public int hashCode()
Description copied from interface: XBRLFactsList
This is from the Object interface and must be implemented by sub classes in order to be able to provide hashCodes

Specified by:
hashCode in interface XBRLFactsList
Overrides:
hashCode in class java.lang.Object
Returns:
integer

equals

public boolean equals(java.lang.Object obj)
Description copied from interface: XBRLFactsList
This function should be implemented by sub classes in order to properly implement

Specified by:
equals in interface XBRLFactsList
Overrides:
equals in class java.lang.Object
Parameters:
obj - Object to compare to
Returns:
boolean value

setParent

public void setParent(XMLHasParent parent)
               throws XBRLInconsistentDTSException
Specified by:
setParent in interface XMLHasParent
Throws:
XBRLInconsistentDTSException

addXMLChild

public void addXMLChild(XMLHasParent child)
                 throws XBRLInconsistentDTSException
Specified by:
addXMLChild in interface XMLHasParent
Throws:
XBRLInconsistentDTSException

removeXMLChild

public void removeXMLChild(XMLHasParent child)
Specified by:
removeXMLChild in interface XMLHasParent

getBase

public java.net.URI getBase()
Specified by:
getBase in interface XMLHasParent

getParent

public XBRLFactsList getParent()
Description copied from interface: XBRLFactsList
Access to the parent document, Instance or tuple

Specified by:
getParent in interface XBRLFactsList
Specified by:
getParent in interface XMLHasParent
Returns:
XMLFragment that is a XBRLInstance or XBRLFactTuple

getInstance

public XBRLInstance getInstance()
Description copied from interface: XBRLFactsList
Access to the instance document on the top of this facts container hierarchy

Specified by:
getInstance in interface XBRLFactsList
Returns:
XBRLInstance

getContainer

public DTSContainer getContainer()
Description copied from interface: XBRLFactsList
Access to the surrounding container object

Specified by:
getContainer in interface XBRLFactsList
Returns:
DTSContainer

getDocument

public net.sf.saxon.s9api.XdmNode getDocument()
Description copied from interface: XBRLFactsList
Access to the surrounding XdmDocument from the XMLFragment

Specified by:
getDocument in interface XBRLFactsList
Returns:
XdmNode according to saxon s9api

getXPathToRoot

public java.lang.String getXPathToRoot()
Description copied from interface: XBRLFactsList
Access to the surrounding method from the XMLFragment

Specified by:
getXPathToRoot in interface XBRLFactsList
Returns:
String

evaluateList

public net.sf.saxon.s9api.XdmValue evaluateList(java.lang.String string)
Description copied from interface: XBRLFactsList
Access to the surrounding method in the XMLFragment

Specified by:
evaluateList in interface XBRLFactsList
Returns:
an XdmValue from the saxonica s9api


Copyright 2006-2009 Reporting Standard S.L., C/ Torrecilla del Puerto 1, 28043, Madrid, Espaņa