[Castore-commits] OutputParagraphElement.java 1.1.2.3 1.1.2.4 TextElement.java 1.1.2.2 1.1.2.3 FlatXmlRawData.java 1.1.2.3 1.1.2.4 ParagraphElement.java 1.1.2.3 1.1.2.4 FxrdElement.java 1.1.2.3 1.1.2.4 LayoutElement.java 1.1.2.3 1.1.2.4 ParagraphComponent.java 1.1.2.2 1.1.2.3

Stéphane Bouchet sbouchet at adullact1.hosting.cri74.org
Lun 6 Mar 17:11:42 CET 2006


Update of /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata
In directory adullact1:/tmp/cvs-serv6611/src/java/fr/emn/castor/documents/retro/flatxmlrawdata

Modified Files:
      Tag: v1_1_branch
	OutputParagraphElement.java TextElement.java 
	FlatXmlRawData.java ParagraphElement.java FxrdElement.java 
	LayoutElement.java ParagraphComponent.java 
Log Message:
Mise en page

Index: FxrdElement.java
===================================================================
RCS file: /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata/FxrdElement.java,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -C2 -d -r1.1.2.3 -r1.1.2.4
*** FxrdElement.java	7 Feb 2006 15:46:10 -0000	1.1.2.3
--- FxrdElement.java	6 Mar 2006 16:11:40 -0000	1.1.2.4
***************
*** 48,58 ****
   */
  public abstract class FxrdElement {
!     
!     public FxrdElement() 
!     {
      }
  
      protected Element targetElement = null;
      protected boolean entirelyProcessed = false;
      /**
       * Display a FxrdElement
--- 48,59 ----
   */
  public abstract class FxrdElement {
! 
!     public FxrdElement() {
      }
  
      protected Element targetElement = null;
+ 
      protected boolean entirelyProcessed = false;
+ 
      /**
       * Display a FxrdElement
***************
*** 60,65 ****
       */
      public void display() {
!     } 
!     
      /**
       * load FxrdElement into a java instance
--- 61,66 ----
       */
      public void display() {
!     }
! 
      /**
       * load FxrdElement into a java instance
***************
*** 68,96 ****
       */
      public abstract void load(Element element);
!     
      /**
       * Reset the FxrdElement to be able to retest it in an updated context
       * 
       */
!     public void Reset()
!     {
!     	if (targetElement != null)
! 		{
! 			targetElement.removeContent();
! 			targetElement.detach();
! 			targetElement = null;
! 		}
!     	entirelyProcessed = false;   	
      }
!     
      /**
       * Tell if the FxrdElement have been entirely tested in the current context
       * 
       */
!     public boolean getEp()
!     {
!     	return true;
      }
-     
  
      /**
--- 69,93 ----
       */
      public abstract void load(Element element);
! 
      /**
       * Reset the FxrdElement to be able to retest it in an updated context
       * 
       */
!     public void Reset() {
!         if (targetElement != null) {
!             targetElement.removeContent();
!             targetElement.detach();
!             targetElement = null;
!         }
!         entirelyProcessed = false;
      }
! 
      /**
       * Tell if the FxrdElement have been entirely tested in the current context
       * 
       */
!     public boolean getEp() {
!         return true;
      }
  
      /**
***************
*** 98,115 ****
       * 
       */
!     public Element getTe()
!     {
!     	return targetElement;
      }
!     
!     public void setTe(Element te)
!     {
!     	targetElement = te;
      }
  
!     public void setEp(boolean ep)
!     {
!     	entirelyProcessed = ep;
      }
  
!  }
--- 95,109 ----
       * 
       */
!     public Element getTe() {
!         return targetElement;
      }
! 
!     public void setTe(Element te) {
!         targetElement = te;
      }
  
!     public void setEp(boolean ep) {
!         entirelyProcessed = ep;
      }
  
! }

Index: FlatXmlRawData.java
===================================================================
RCS file: /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata/FlatXmlRawData.java,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -C2 -d -r1.1.2.3 -r1.1.2.4
*** FlatXmlRawData.java	7 Feb 2006 15:46:10 -0000	1.1.2.3
--- FlatXmlRawData.java	6 Mar 2006 16:11:40 -0000	1.1.2.4
***************
*** 56,63 ****
  
  public class FlatXmlRawData {
!     
      /** le logger.*/
      private static Log logger = LogFactory.getLog(FlatXmlRawData.class);
!     
      /**
       * Class members
--- 56,63 ----
  
  public class FlatXmlRawData {
! 
      /** le logger.*/
      private static Log logger = LogFactory.getLog(FlatXmlRawData.class);
! 
      /**
       * Class members
***************
*** 71,75 ****
      // the namespace
      protected String targetNamespace;
!     
      // the contained elements
      protected Vector<FxrdElement> fxrdElements;
--- 71,75 ----
      // the namespace
      protected String targetNamespace;
! 
      // the contained elements
      protected Vector<FxrdElement> fxrdElements;
***************
*** 98,105 ****
  
      /**
! 	 * getter method for fxrdFilePath attribute
! 	 * @return  the file path attribute
! 	 * @uml.property  name="fxrdFilePath"
! 	 */
      public String getFxrdFilePath() {
          return fxrdFilePath;
--- 98,105 ----
  
      /**
!      * getter method for fxrdFilePath attribute
!      * @return  the file path attribute
!      * @uml.property  name="fxrdFilePath"
!      */
      public String getFxrdFilePath() {
          return fxrdFilePath;
***************
*** 107,114 ****
  
      /**
! 	 * getter method for rootElement attribute
! 	 * @return  the root element name
! 	 * @uml.property  name="rootElement"
! 	 */
      public String getRootElement() {
          return rootElement;
--- 107,114 ----
  
      /**
!      * getter method for rootElement attribute
!      * @return  the root element name
!      * @uml.property  name="rootElement"
!      */
      public String getRootElement() {
          return rootElement;
***************
*** 116,132 ****
  
      /**
! 	 * getter method for targetNamespace attribute
! 	 * @return  the targetNamespace
! 	 * @uml.property  name="targetNamespace"
! 	 */
      public String getTargetNamespace() {
          return targetNamespace;
      }
!     
      /**
! 	 * getter method for fxrdElements attribute
! 	 * @return  the vector of the fxrdElements contained in the document
! 	 * @uml.property  name="fxrdElements"
! 	 */
      public Vector<FxrdElement> getFxrdElements() {
          return fxrdElements;
--- 116,132 ----
  
      /**
!      * getter method for targetNamespace attribute
!      * @return  the targetNamespace
!      * @uml.property  name="targetNamespace"
!      */
      public String getTargetNamespace() {
          return targetNamespace;
      }
! 
      /**
!      * getter method for fxrdElements attribute
!      * @return  the vector of the fxrdElements contained in the document
!      * @uml.property  name="fxrdElements"
!      */
      public Vector<FxrdElement> getFxrdElements() {
          return fxrdElements;
***************
*** 139,143 ****
      public void load() /* throws DOMException */
      {
! 		Document fxrdDoc = XMLUtils.getDocumentFromXMLFile(fxrdFilePath);
          Element docElem = fxrdDoc.getRootElement();
          loadRootElement(docElem);
--- 139,143 ----
      public void load() /* throws DOMException */
      {
!         Document fxrdDoc = XMLUtils.getDocumentFromXMLFile(fxrdFilePath);
          Element docElem = fxrdDoc.getRootElement();
          loadRootElement(docElem);
***************
*** 152,176 ****
          List docElementList = docElem.getChildren();
  
!         int elementsCount = docElementList.size()+1;
          // create all FxrdElements 
          // Load information from input FlatXmlRawData file
!         for (int i = 0; i < elementsCount - 1; i++) 
!         {
!         	Element ithElement = (Element) docElementList.get(i);        	
              FxrdElement ithFxrdElement;
!             
!             if (ithElement.getName().equals(PARAGRAPH_ELEMENT)) 
!             {          
!             	ithFxrdElement  = new ParagraphElement();
!             }
!             else
!             {
!             	ithFxrdElement = new LayoutElement();
              }
!         	// load it with XML info
!         	ithFxrdElement.load(ithElement);            
              // add it to the Vector
              fxrdElements.add(ithFxrdElement);
!         }			
      }
  
--- 152,172 ----
          List docElementList = docElem.getChildren();
  
!         int elementsCount = docElementList.size() + 1;
          // create all FxrdElements 
          // Load information from input FlatXmlRawData file
!         for (int i = 0; i < elementsCount - 1; i++) {
!             Element ithElement = (Element) docElementList.get(i);
              FxrdElement ithFxrdElement;
! 
!             if (ithElement.getName().equals(PARAGRAPH_ELEMENT)) {
!                 ithFxrdElement = new ParagraphElement();
!             } else {
!                 ithFxrdElement = new LayoutElement();
              }
!             // load it with XML info
!             ithFxrdElement.load(ithElement);
              // add it to the Vector
              fxrdElements.add(ithFxrdElement);
!         }
      }
  
***************
*** 192,200 ****
       */
      public void loadTargetNamespace(Element docElem) {
!         Attribute targetNamespaceAttribute = docElem.getAttribute(TARGET_NAMESPACE);
          if (targetNamespaceAttribute != null)
!         	targetNamespace = targetNamespaceAttribute.getValue();
      }
!     
      /**
       * display the document
--- 188,197 ----
       */
      public void loadTargetNamespace(Element docElem) {
!         Attribute targetNamespaceAttribute = docElem
!             .getAttribute(TARGET_NAMESPACE);
          if (targetNamespaceAttribute != null)
!             targetNamespace = targetNamespaceAttribute.getValue();
      }
! 
      /**
       * display the document
***************
*** 218,227 ****
      // used in OutputDocumentGenerator
      public static final String ROOT_ELEMENT = "rootElement";
      public static final String TARGET_NAMESPACE = "namespace";
!     
      public static final String PARAGRAPH_ELEMENT = "ParagraphElement";
  
      public static final String LAYOUT_ELEMENT = "LayoutElement";
!     
!     public static Namespace NAMESPACE= Namespace.getNamespace("urn:xgs:names:reverse:xmlns:fxrd:1.0");
  }
--- 215,226 ----
      // used in OutputDocumentGenerator
      public static final String ROOT_ELEMENT = "rootElement";
+ 
      public static final String TARGET_NAMESPACE = "namespace";
! 
      public static final String PARAGRAPH_ELEMENT = "ParagraphElement";
  
      public static final String LAYOUT_ELEMENT = "LayoutElement";
! 
!     public static Namespace NAMESPACE = Namespace
!         .getNamespace("urn:xgs:names:reverse:xmlns:fxrd:1.0");
  }

Index: ParagraphComponent.java
===================================================================
RCS file: /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata/ParagraphComponent.java,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -C2 -d -r1.1.2.2 -r1.1.2.3
*** ParagraphComponent.java	7 Feb 2006 15:46:10 -0000	1.1.2.2
--- ParagraphComponent.java	6 Mar 2006 16:11:40 -0000	1.1.2.3
***************
*** 43,50 ****
  public class ParagraphComponent extends FxrdElement {
  
! 	public void load(Element element) {
! 		// TODO Auto-generated method stub
  
! 	}
  
  }
--- 43,50 ----
  public class ParagraphComponent extends FxrdElement {
  
!     public void load(Element element) {
!         // TODO Auto-generated method stub
  
!     }
  
  }

Index: LayoutElement.java
===================================================================
RCS file: /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata/LayoutElement.java,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -C2 -d -r1.1.2.3 -r1.1.2.4
*** LayoutElement.java	7 Feb 2006 15:46:10 -0000	1.1.2.3
--- LayoutElement.java	6 Mar 2006 16:11:40 -0000	1.1.2.4
***************
*** 53,56 ****
--- 53,57 ----
      /** le logger.*/
      private static Log logger = LogFactory.getLog(LayoutElement.class);
+ 
      /**
       * Default constructor
***************
*** 68,103 ****
       */
      // a vector of ParagraphElements
!     protected Vector<ParagraphElement> substituteParagraphElements;   
      protected Element outputLayoutElement;
      protected boolean processedOutputLayoutElement = false;
-     
- 	public void Reset()
- 	{
- 		super.Reset();
- 		if (substituteParagraphElements != null)
- 		{
- 			for (int i=0; i< substituteParagraphElements.size(); i++)
- 			{
- 				((ParagraphElement) substituteParagraphElements.get(i)).Reset();
- 			}			
- 		}
- 		processedOutputLayoutElement = false;
- 	}
- 	
- 	public boolean getPole()
- 	{
- 		return processedOutputLayoutElement;
- 	}
  
! 	public void setPole(boolean pole)
! 	{
! 		processedOutputLayoutElement = pole;
! 	}
! 	
      /**
! 	 * getter method for outputLayoutElement attribute
! 	 * @return  the attribute
! 	 * @uml.property  name="outputLayoutElement"
! 	 */
      public Element getOutputLayoutElement() {
          return outputLayoutElement;
--- 69,102 ----
       */
      // a vector of ParagraphElements
!     protected Vector<ParagraphElement> substituteParagraphElements;
! 
      protected Element outputLayoutElement;
+ 
      protected boolean processedOutputLayoutElement = false;
  
!     public void Reset() {
!         super.Reset();
!         if (substituteParagraphElements != null) {
!             for (int i = 0; i < substituteParagraphElements.size(); i++) {
!                 ((ParagraphElement) substituteParagraphElements.get(i))
!                     .Reset();
!             }
!         }
!         processedOutputLayoutElement = false;
!     }
! 
!     public boolean getPole() {
!         return processedOutputLayoutElement;
!     }
! 
!     public void setPole(boolean pole) {
!         processedOutputLayoutElement = pole;
!     }
! 
      /**
!      * getter method for outputLayoutElement attribute
!      * @return  the attribute
!      * @uml.property  name="outputLayoutElement"
!      */
      public Element getOutputLayoutElement() {
          return outputLayoutElement;
***************
*** 105,128 ****
  
      /**
! 	 * getter method for substituteParagraphElements attribute
! 	 * @return  the attribute
! 	 * @uml.property  name="substituteParagraphElements"
! 	 */
      public Vector<ParagraphElement> getSubstituteParagraphElements() {
          return substituteParagraphElements;
      }
  
!     protected Class getParagraphElementClass()
! 	{
!     	Class peClass = null;
! 		try {
! 			peClass = Class.forName("ParagraphElement");
! 		} catch (ClassNotFoundException e) {
! 			// TODO Auto-generated catch block
! 			e.printStackTrace();
! 		}
! 		return peClass;
! 	}
!     
      /**
       * load layoutElement into a java instance
--- 104,126 ----
  
      /**
!      * getter method for substituteParagraphElements attribute
!      * @return  the attribute
!      * @uml.property  name="substituteParagraphElements"
!      */
      public Vector<ParagraphElement> getSubstituteParagraphElements() {
          return substituteParagraphElements;
      }
  
!     protected Class getParagraphElementClass() {
!         Class peClass = null;
!         try {
!             peClass = Class.forName("ParagraphElement");
!         } catch (ClassNotFoundException e) {
!             // TODO Auto-generated catch block
!             e.printStackTrace();
!         }
!         return peClass;
!     }
! 
      /**
       * load layoutElement into a java instance
***************
*** 130,137 ****
       * @param layoutElement
       */
!     public void load(Element element) 
!     {
!     	
!     	outputLayoutElement = (Element) element.getChild(OUTPUT_LAYOUT_ELEMENT, FlatXmlRawData.NAMESPACE).getChildren().get(0);
  
          // load substitudeParagraphElements
--- 128,136 ----
       * @param layoutElement
       */
!     public void load(Element element) {
! 
!         outputLayoutElement = (Element) element
!             .getChild(OUTPUT_LAYOUT_ELEMENT, FlatXmlRawData.NAMESPACE)
!             .getChildren().get(0);
  
          // load substitudeParagraphElements
***************
*** 144,161 ****
       * @param layoutElement
       */
!     private void loadSubstituteParagraphElements(Element layoutElement) 
!     {
!         Element substitudeParagraphElementNode = layoutElement.getChild(SUBSTITUTE_PARAGRAPH_ELEMENTS, FlatXmlRawData.NAMESPACE);
!         if (substitudeParagraphElementNode != null) 
!         {
!             List paraElemList = substitudeParagraphElementNode.getChildren(PARAGRAPH_ELEMENT, FlatXmlRawData.NAMESPACE);
!             
!             for (int i=0; i< paraElemList.size(); i++) 
!             {
                  // Create a new ParagraphElement
                  ParagraphElement pElem = new ParagraphElement();
  
                  // load it
!                 pElem.load((Element)paraElemList.get(i));
                  // add it to the substituteParagraphElements vector
                  substituteParagraphElements.add(pElem);
--- 143,159 ----
       * @param layoutElement
       */
!     private void loadSubstituteParagraphElements(Element layoutElement) {
!         Element substitudeParagraphElementNode = layoutElement.getChild(
!             SUBSTITUTE_PARAGRAPH_ELEMENTS, FlatXmlRawData.NAMESPACE);
!         if (substitudeParagraphElementNode != null) {
!             List paraElemList = substitudeParagraphElementNode.getChildren(
!                 PARAGRAPH_ELEMENT, FlatXmlRawData.NAMESPACE);
! 
!             for (int i = 0; i < paraElemList.size(); i++) {
                  // Create a new ParagraphElement
                  ParagraphElement pElem = new ParagraphElement();
  
                  // load it
!                 pElem.load((Element) paraElemList.get(i));
                  // add it to the substituteParagraphElements vector
                  substituteParagraphElements.add(pElem);
***************
*** 173,177 ****
          logger.debug("end of LayoutElement");
      }
!     
      /**
       * Display the substitute paragraph elements
--- 171,175 ----
          logger.debug("end of LayoutElement");
      }
! 
      /**
       * Display the substitute paragraph elements
***************
*** 180,185 ****
      public void displaySubstituteParagraphElements() {
          logger.debug("SubstituteParagraphElements");
!         for (int i=0; i<substituteParagraphElements.size();i++) {
!             ((ParagraphElement)substituteParagraphElements.get(i)).display();
          }
          logger.debug("end of SubstituteParagraphElements");
--- 178,184 ----
      public void displaySubstituteParagraphElements() {
          logger.debug("SubstituteParagraphElements");
!         for (int i = 0; i < substituteParagraphElements.size(); i++) {
!             ((ParagraphElement) substituteParagraphElements.get(i))
!                 .display();
          }
          logger.debug("end of SubstituteParagraphElements");

Index: OutputParagraphElement.java
===================================================================
RCS file: /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata/OutputParagraphElement.java,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -C2 -d -r1.1.2.3 -r1.1.2.4
*** OutputParagraphElement.java	7 Feb 2006 15:46:10 -0000	1.1.2.3
--- OutputParagraphElement.java	6 Mar 2006 16:11:39 -0000	1.1.2.4
***************
*** 49,55 ****
  
      /** le logger.*/
!     private static Log logger = LogFactory.getLog(OutputParagraphElement.class);
!     
! 	/**
       * Default constructor
       *  
--- 49,56 ----
  
      /** le logger.*/
!     private static Log logger = LogFactory
!         .getLog(OutputParagraphElement.class);
! 
!     /**
       * Default constructor
       *  
***************
*** 74,85 ****
      public void load(Element outputParaElem) {
          name = outputParaElem.getAttributeValue(ATTR_NAME);
!         containerElement = outputParaElem.getAttributeValue(ATTR_CONTAINER_ELEMENT);
      }
  
      /**
! 	 * getter method for "name" attribute
! 	 * @return  name
! 	 * @uml.property  name="name"
! 	 */
      public String getName() {
          return name;
--- 75,87 ----
      public void load(Element outputParaElem) {
          name = outputParaElem.getAttributeValue(ATTR_NAME);
!         containerElement = outputParaElem
!             .getAttributeValue(ATTR_CONTAINER_ELEMENT);
      }
  
      /**
!      * getter method for "name" attribute
!      * @return  name
!      * @uml.property  name="name"
!      */
      public String getName() {
          return name;
***************
*** 87,94 ****
  
      /**
! 	 * getter methode for containerElement attribute
! 	 * @return  the container element
! 	 * @uml.property  name="containerElement"
! 	 */
      public String getContainerElement() {
          return containerElement;
--- 89,96 ----
  
      /**
!      * getter methode for containerElement attribute
!      * @return  the container element
!      * @uml.property  name="containerElement"
!      */
      public String getContainerElement() {
          return containerElement;

Index: TextElement.java
===================================================================
RCS file: /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata/TextElement.java,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -C2 -d -r1.1.2.2 -r1.1.2.3
*** TextElement.java	7 Feb 2006 15:46:10 -0000	1.1.2.2
--- TextElement.java	6 Mar 2006 16:11:40 -0000	1.1.2.3
***************
*** 46,64 ****
  public class TextElement extends ParagraphComponent {
  
! 	protected String value = "";
! 	
! 	public void load(Element element) 
! 	{
! 		value = element.getText();
! 	}
! 	
! 	/**
! 	 * @return  Returns the value.
! 	 * @uml.property  name="value"
! 	 */
! 	public String getValue()
! 	{
! 		return value;
! 	}
  
  }
--- 46,62 ----
  public class TextElement extends ParagraphComponent {
  
!     protected String value = "";
! 
!     public void load(Element element) {
!         value = element.getText();
!     }
! 
!     /**
!      * @return  Returns the value.
!      * @uml.property  name="value"
!      */
!     public String getValue() {
!         return value;
!     }
  
  }

Index: ParagraphElement.java
===================================================================
RCS file: /cvsroot/castore/castore-core/src/java/fr/emn/castor/documents/retro/flatxmlrawdata/ParagraphElement.java,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -C2 -d -r1.1.2.3 -r1.1.2.4
*** ParagraphElement.java	7 Feb 2006 15:46:10 -0000	1.1.2.3
--- ParagraphElement.java	6 Mar 2006 16:11:40 -0000	1.1.2.4
***************
*** 55,59 ****
      /** le logger.*/
      private static Log logger = LogFactory.getLog(ParagraphElement.class);
!     
      /**
       * Default constructor
--- 55,59 ----
      /** le logger.*/
      private static Log logger = LogFactory.getLog(ParagraphElement.class);
! 
      /**
       * Default constructor
***************
*** 70,106 ****
       * Class members
       */
!     public Vector<ParagraphComponent> paragraphComponents;    
      public Vector<OutputParagraphElement> outputParagraphElements;
      public Collection ParagraphElementsFromSchema;
- 	protected int lastProcessedOutputParagraphElement = -1;
- 	protected Iterator iteratorParagraphElementsFromSchema = null; 
- 	
- 	public void Reset()
- 	{		
- 		super.Reset();
- 		lastProcessedOutputParagraphElement = -1;
- 		iteratorParagraphElementsFromSchema = null;
- 		ParagraphElementsFromSchema = null;
- 	}
- 	
- 	public int getLpope()
- 	{
- 		return lastProcessedOutputParagraphElement;
- 	}
  
! 	public void setLpope(int lpope)
! 	{
! 		lastProcessedOutputParagraphElement = lpope;
! 	}
  
! 	public Iterator getIpefs()
! 	{
! 		return iteratorParagraphElementsFromSchema;
! 	}
  
! 	public void setIpefs(Iterator ippefs)
! 	{
! 		iteratorParagraphElementsFromSchema = ippefs;
! 	}
  
      /**
--- 70,105 ----
       * Class members
       */
!     public Vector<ParagraphComponent> paragraphComponents;
! 
      public Vector<OutputParagraphElement> outputParagraphElements;
+ 
      public Collection ParagraphElementsFromSchema;
  
!     protected int lastProcessedOutputParagraphElement = -1;
  
!     protected Iterator iteratorParagraphElementsFromSchema = null;
  
!     public void Reset() {
!         super.Reset();
!         lastProcessedOutputParagraphElement = -1;
!         iteratorParagraphElementsFromSchema = null;
!         ParagraphElementsFromSchema = null;
!     }
! 
!     public int getLpope() {
!         return lastProcessedOutputParagraphElement;
!     }
! 
!     public void setLpope(int lpope) {
!         lastProcessedOutputParagraphElement = lpope;
!     }
! 
!     public Iterator getIpefs() {
!         return iteratorParagraphElementsFromSchema;
!     }
! 
!     public void setIpefs(Iterator ippefs) {
!         iteratorParagraphElementsFromSchema = ippefs;
!     }
  
      /**
***************
*** 110,150 ****
       */
      public void load(Element element) {
!     	
!     	Element paragraphContent = element.getChild(PARAGRAPH_CONTENT, FlatXmlRawData.NAMESPACE);
!     	if (paragraphContent != null)
!     	{
!     		
!     		List paragraphComponentNodeList = paragraphContent.getChildren();
!     		ParagraphComponent paragraphComponent;
!     		
!     		for (int i=0; i < paragraphComponentNodeList.size(); i++)
!     		{
!     			Element paragraphComponentNode = (Element) paragraphComponentNodeList.get(i);
!     	        
!     	        if (paragraphComponentNode.getName().equals(TEXT_ELEMENT)) 
!     	        {          
!     	        	paragraphComponent = new TextElement();
!     	        }
!     	        else
!     	        {
!     	        	if (paragraphComponentNode.getName().equals(INLINE_LAYOUT_ELEMENT))
!     	        	{
!     	        		paragraphComponent = new InlineLayoutElement();
!     	        	}
!     	        	else
!     	        	{
!     	        		// InlineTextualElement
!     	        		paragraphComponent = new InlineTextualElement();
!     	        	}
!     	        }
! 	        	// load it with XML info
! 	        	paragraphComponent.load(paragraphComponentNode);
! 	        	// add it to the Vector	
! 	        	paragraphComponents.add(paragraphComponent);    	        
!     		}
!     	}			
  
          // load OutPutParagraphElements
!         List outputParaElemList = element.getChildren(OUTPUT_PARA_ELEM, FlatXmlRawData.NAMESPACE);
          if (outputParaElemList == null)
              return;
--- 109,145 ----
       */
      public void load(Element element) {
! 
!         Element paragraphContent = element.getChild(
!             PARAGRAPH_CONTENT, FlatXmlRawData.NAMESPACE);
!         if (paragraphContent != null) {
! 
!             List paragraphComponentNodeList = paragraphContent.getChildren();
!             ParagraphComponent paragraphComponent;
! 
!             for (int i = 0; i < paragraphComponentNodeList.size(); i++) {
!                 Element paragraphComponentNode = (Element) paragraphComponentNodeList
!                     .get(i);
! 
!                 if (paragraphComponentNode.getName().equals(TEXT_ELEMENT)) {
!                     paragraphComponent = new TextElement();
!                 } else {
!                     if (paragraphComponentNode.getName().equals(
!                         INLINE_LAYOUT_ELEMENT)) {
!                         paragraphComponent = new InlineLayoutElement();
!                     } else {
!                         // InlineTextualElement
!                         paragraphComponent = new InlineTextualElement();
!                     }
!                 }
!                 // load it with XML info
!                 paragraphComponent.load(paragraphComponentNode);
!                 // add it to the Vector	
!                 paragraphComponents.add(paragraphComponent);
!             }
!         }
  
          // load OutPutParagraphElements
!         List outputParaElemList = element.getChildren(
!             OUTPUT_PARA_ELEM, FlatXmlRawData.NAMESPACE);
          if (outputParaElemList == null)
              return;
***************
*** 165,170 ****
          logger.debug("ParagraphElement");
          logger.debug("  ParagraphContent = ");
!         for (int i = 0;  i < paragraphComponents.size(); i++) 
!         {
              ((ParagraphComponent) paragraphComponents.get(i)).display();
          }
--- 160,164 ----
          logger.debug("ParagraphElement");
          logger.debug("  ParagraphContent = ");
!         for (int i = 0; i < paragraphComponents.size(); i++) {
              ((ParagraphComponent) paragraphComponents.get(i)).display();
          }
***************
*** 173,177 ****
              for (int i = 0; i < outputParagraphElements.size(); i++) {
                  ((OutputParagraphElement) outputParagraphElements.get(i))
!                         .display();
              }
          }
--- 167,171 ----
              for (int i = 0; i < outputParagraphElements.size(); i++) {
                  ((OutputParagraphElement) outputParagraphElements.get(i))
!                     .display();
              }
          }
***************
*** 180,196 ****
  
      /**
! 	 * getter method for paragraphComponents attribute
! 	 * @return
! 	 * @uml.property  name="paragraphComponents"
! 	 */
      public Vector getParagraphComponents() {
          return paragraphComponents;
      }
!     
      /**
! 	 * getter method for outputParagraphElements attribute
! 	 * @return
! 	 * @uml.property  name="outputParagraphElements"
! 	 */
      public Vector getOutputParagraphElements() {
          return outputParagraphElements;
--- 174,190 ----
  
      /**
!      * getter method for paragraphComponents attribute
!      * @return
!      * @uml.property  name="paragraphComponents"
!      */
      public Vector getParagraphComponents() {
          return paragraphComponents;
      }
! 
      /**
!      * getter method for outputParagraphElements attribute
!      * @return
!      * @uml.property  name="outputParagraphElements"
!      */
      public Vector getOutputParagraphElements() {
          return outputParagraphElements;
***************
*** 202,207 ****
       */
      private static final String PARAGRAPH_CONTENT = "ParagraphContent";
      private static final String TEXT_ELEMENT = "Text";
!     private static final String INLINE_LAYOUT_ELEMENT = "InlineLayoutElement";  
      private static final String OUTPUT_PARA_ELEM = "OutputParagraphElement";
  }
--- 196,204 ----
       */
      private static final String PARAGRAPH_CONTENT = "ParagraphContent";
+ 
      private static final String TEXT_ELEMENT = "Text";
! 
!     private static final String INLINE_LAYOUT_ELEMENT = "InlineLayoutElement";
! 
      private static final String OUTPUT_PARA_ELEM = "OutputParagraphElement";
  }




Plus d'informations sur la liste de diffusion Castore-commits