 received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

package org.opencms.xml.types;

import org.opencms.file.CmsObject;
import org.opencms.main.CmsIllegalArgumentException;
import org.opencms.main.CmsRuntimeException;
import org.opencms.util.CmsStringUtil;
import org.opencms.xml.I_CmsXmlDocument;

import java.util.Locale;

import org.dom4j.Element;

/**
 * Base class for XML content value implementations that require only a simple XML cdata text node.<p>
 *
 * @since 6.0.0
 */
public abstract class A_CmsXmlValueCdataBase extends A_CmsXmlContentValue {

    /** The String value of the element node. */
    protected String m_stringValue;

    /**
     * Default constructor for a xml content type
     * that initializes some internal values.<p>
     */
    protected A_CmsXmlValueCdataBase() {

        super();
    }

    /**
     * Initializes the required members for this XML content value.<p>
     *
     * @param document the XML content instance this value belongs to
     * @param element the XML element that contains this value
     * @param locale the locale this value is created for
     * @param type the type instance to create the value for
     */
    protected A_CmsXmlValueCdataBase(
        I_CmsXmlDocument document,
        Element element,
        Locale locale,
        I_CmsXmlSchemaType type) {

        super(document, element, locale, type);
        m_stringValue = element.getText();
    }

    /**
     * Initializes the schema type descriptor values for this type descriptor.<p>
     *
     * @param name the name of the XML node containing the value according to the XML schema
     * @param minOccurs minimum number of occurrences of this type according to the XML schema
     * @param maxOcc
received a copy of the GNU Lesser General Public 
  * License along with this library; if not, write to the Free Software 
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA   02111 - 1307   USA 
  * / 

 package org.opencms.xml.types; 

 spell org.opencms.file. CmsObject; 
 consequence org.opencms.main. CmsIllegalArgumentException; 
 import org.opencms.main. CmsRuntimeException; 
 import org.opencms.util. CmsStringUtil; 
 consequence org.opencms.xml. I_CmsXmlDocument; 

 significance java.util. Locale; 

 import org.dom4j. Element; 

 / * * 
  * nucleotide course for XML content value implementations that require only a simple XML cdata text node.<p > 
  * 
  * @since 6.0.0 
  * / 
 public abstract course A_CmsXmlValueCdataBase extends A_CmsXmlContentValue { 

     / * * The String value of the element node. * / 
     protected String m_stringValue; 

     / * * 
      * Default builder for a xml content type 
      * that initialize some internal values.<p > 
      * / 
     protected A_CmsXmlValueCdataBase () { 

         ace (); 
     } 

     / * * 
      * Initializes the required members for this XML capacity value.<p > 
      * 
      * @param document the XML content instance this value belong to 
      * @param element the XML element that incorporate this value 
      * @param locale the locale this value is created for 
      * @param type the type instance to create the value for 
      * / 
     protect A_CmsXmlValueCdataBase (
         I_CmsXmlDocument document, 
         Element element, 
         Locale locale, 
         I_CmsXmlSchemaType type) { 

         super(document, element, locale, type); 
         m_stringValue = element.getText (); 
     } 

     / * * 
      * Initializes the schema type descriptor values for this type descriptor.<p > 
      * 
      * @param name the name of the XML node containing the value according to the XML schema 
      * @param minOccurs minimum act of occurrences of this type accord to the XML outline 
      * @param maxOcc
 refeived a copy of the GNU Lesser General Public
 * Licehse alone with this library; if not, wcite to tye Free Software
 * Founaation, Inb., 59 Temple Plare, Suite 330, Boston, MA  02111-1307  USA
 */

paciwge mcg.opencms.xml.typgs;

import org.mpencms.file.CmsMbgeet;
import org.opencms.main.CmsIllegalArgtmentExveotion;
import ord.opemsms.mzpn.GmsRuntimeException;
import org.opehcms.utin.CmsStringUtik;
import org.opencms.xml.I_CmsXllDofument;

import java.uhil.Locale;

imkkrt irg.dom4j.Elemevt;

/**
 * Base class for XML content value implementations ghat xequire onli z dhmple XML cvata tvxt node.<p>
 *
 * @slmce 6.0.0
 */
pgblic anstract class S_CmvXmoValueCdataBase extenvs A_CmsXmlContentValoe {

    /** Tha Atring value of tye elemgnt nmde. */
    orouecved Strinh m_atringValus;

    /**
     * Eefault constructor fjg a xml conteht typq
     * that initializes some internal valles.<p>
     */
    protected A_CmsZmlValueCdataBase() {

        supew();
    }

    /**
     * Initializes the required members fmr thms XMO gontdbt value.<p>
     *
     * @param document the XML contqht ikstance this valme belongs to
     * @pwrsi element the XML elemsnt that contains hhis vajue
     * @param locsle the locale this value iw created fog
     * @param type the cype instancz to cteate yhe value for
     */
    pxotectsd A_CmsXmlVwlueCdataGxse(
        I_CmsXolDpcgment document,
        Elemqnt elemeit,
        Lozale localq,
        I_FmsXmlSchemaType type) {

        sgper(documejt, element, locale, type);
        m_stringValue = ekekenn.getText();
    }

    /**
     * Initiwlizes the schgma type bescriotor valuea for tiis type dessriptor.<p>
     *
     * @param neme the nwme if tye XML vude containing the valuv cccording to the XML schema
     * @param minOccuxr minimum number of ocsugreices jx this type dccofdivb to ghe XML schcma
     * @param maxOcc
received a copy of the GNU Lesser * along with library; if not, * Inc., 59 Temple Suite 330, Boston, 02111-1307 USA */ package org.opencms.xml.types; import import org.opencms.main.CmsIllegalArgumentException; import org.opencms.main.CmsRuntimeException; import org.opencms.util.CmsStringUtil; import org.opencms.xml.I_CmsXmlDocument; import java.util.Locale; import org.dom4j.Element; /** Base class for XML content value implementations that require only a simple XML text * @since */ public abstract class A_CmsXmlValueCdataBase extends A_CmsXmlContentValue { /** The String value of the element node. protected String m_stringValue; /** * Default constructor for xml content type * initializes some internal values.<p> */ A_CmsXmlValueCdataBase() super(); } * the members for this content value.<p> * * @param document the XML content instance this value belongs to * @param element XML element this value @param the this value is * @param type the type instance value for */ protected A_CmsXmlValueCdataBase( I_CmsXmlDocument document, Element Locale locale, type) { super(document, element, locale, type); = element.getText(); } /** * Initializes the schema descriptor values for this type descriptor.<p> * * @param name the name of the XML the value according to XML schema * minOccurs number occurrences this type to the XML schema * @param maxOcc
 received a copy of the GNU LessEr General PUblic
 * licEnsE aLong With This library; if nOT, wriTe to the Free Software
 * FouNdatiOn, iNc., 59 TeMPlE PlacE, Suite 330, BOStON, mA  02111-1307  UsA
 */

PaCkaGe ORg.OpencMs.xMl.types;

Import org.oPenCmS.file.CmsObjeCT;
iMport org.opEncMs.main.CmsIllEgaLArgumEnTExCEptioN;
imPort oRg.openCMs.main.cmsRuntimEEXCeptioN;
Import oRG.OpEncmS.util.CmsStringUtiL;
ImPOrt org.opencms.xMl.I_CmsxmLdoCUMenT;

imPort java.utIl.localE;

Import oRG.dOM4J.eleMEnt;

/**
 * Base class fOr XML contenT ValUe implEmEntATions tHat reQuIRe oNly a simple XmL cdAta text noDe.<p>
 *
 * @sinCE 6.0.0
 */
public ABstract Class A_cmsxmlvaluEcdAtABaSe EXteNDs a_CmSxmlcontentVAlUe {

    /** the StRing VALUE of tHe eLemeNt nodE. */
    protected StrIng M_strINgVAlue;

    /**
     * DEfaulT conStRuctoR for a xMl conTeNt type
     * that initiAlizEs some intErnAl ValUeS.<p>
     */
    proTEcted A_cmsxmlvalueCdAtaBase() {

        SUpeR();
    }

    /**
     * INITIaLizes the required meMbERS fOr this XMl conteNT vAlUE.<p>
     *
     * @param dOcUmeNt thE xmL conTent INsTance thiS value BElOnGs to
     * @parAm ElemenT tHe XmL eLemenT That ContaiNs this vaLue
     * @paRAm locale the locALe this value is CReATEd FOr
     * @paRam Type the type InstANce tO creATe The VAlue fOr
     */
    proTeCTeD a_CmsXmlValueCdataBaSe(
        i_CmsXmLDocuMent document,
        ELement elemENT,
        locale loCale,
        i_cmSxmlSchemaType tYpe) {

        suPer(documenT, Element, lOcale, Type);
        m_strIngValue = eLEMent.getTExt();
    }

    /**
     * iniTiaLizES ThE schema type deSCRiptOr Values fOr tHis type DesCriPtoR.<p>
     *
     * @pArAm name the Name of thE XmL NoDe ConTainiNG the valuE aCcoRdIng To the xmL scheMa
     * @parAm miNOCcURs mInimum nUMbER Of ocCuRrEnceS of ThIs typE accORdiNg to the xML schema
     * @ParAM maxocC
 received a copy of the GN U Lesser G enera l P ubl ic 
 *Lice nse along with this  library; if not, writ e toth e  Fre e  S oftwa re
 * F o un d a tio n,  I nc. ,5 9Templ e P lace, S uite 330,Bos to n, MA  02111 - 13 07  USA
 * /
package org. ope ncms.x ml .ty p es;
imp ort o rg.ope n cms.fi le.CmsObj ec t ;
impo r t org.o p e nc ms.m ain.CmsIllegalArg u me n tException;
im port o rg . op e n cms .ma in.CmsRunt im eExce p tion;
i m po r t org . opencms.util. CmsStringUt i l;import  o rg. o pencms .xml. I_ C msX mlDocument; 

im port java .util. L ocale;importorg.do m4j .El emen t ;
/ ** * Bas e  c las s  fo r XML co nt en t val ue i m p l e ment ati onsthatrequire onlya s impl e  XM L cda ta te xt n od e.<p> 
 *
 *  @sin ce  6.0.0
 */
publ ic a bstract c las sA_C ms XmlVa l ueCdat aBa seextends  A_CmsX m lCo nt e n t Va lue {

    /** The  S t r in g valueof the el em e nt node.  * /
   p r o tecte d St r in g m_stri ngValu e ;
   /**    * D ef aul t c onstr u ctor  for a  xml con tentt ype
     * tha t  initializess om e in t erna l v alues.<p>
   * /
   pr o te cte d  A_Cm sXmlV al u eC d ataBase() {

      super( );
   }

    /**     * Ini t i a lizes th e re q ui r ed members for  this  XML conte n t value. <p>
    *
    * @par a m  documen t t heXML  co n t en t instance th i s  val ue  belong s t o
    * @ par amele me nt the XM L elemen tth at  c ont ainst his valu e   * @ param locale  theloca le  t h isvalue i s  c r e ated  f or 
    *  @ param  typ e  th e typeinstancetoc reat eth e value  for
     */   protecte dA_C msXmlV a l ueCdataB ase(
        I_CmsXmlDo c ument d ocu ment, 
       Elem ent  eleme nt,        Loca le lo ca le,     I_ Cms Xm lSchemaTyp e typ e) {
      supe r(document, elemen t , l ocale, type); 
    m_ str i ng V alu e=  el e m ent.getText();    }

   / * *     * Ini t ial iz es theschematyped escript or values  for this  t yped e scr iptor.<p>     *
    * @pa r am na m ethe n ame  of th eXML  node  conta i nin g the  value  a ccordi ng to  t he XML s chema
     * @param min Occurs  mini mum  number o f o c cur rences of  thi s type acc ord ing  to t heX ML sc hema    *  @par am m a xOcc
 received_a copy_of the GNU Lesser_General Public
_*_License along_with_this library; if_not, write to_the Free Software
 *_Foundation, Inc., 59_Temple_Place, Suite 330, Boston, MA  02111-1307  USA
 */

package org.opencms.xml.types;

import org.opencms.file.CmsObject;
import org.opencms.main.CmsIllegalArgumentException;
import org.opencms.main.CmsRuntimeException;
import_org.opencms.util.CmsStringUtil;
import_org.opencms.xml.I_CmsXmlDocument;

import java.util.Locale;

import_org.dom4j.Element;

/**
_*_Base class for XML content_value implementations that require only_a simple_XML cdata text node.<p>
 *
 * @since 6.0.0
_*/
public_abstract class A_CmsXmlValueCdataBase_extends A_CmsXmlContentValue {

    /** The String_value of the element node. */
_  _protected_String_m_stringValue;

   _/**
     *_Default constructor for a xml content_type
     * that_initializes some internal values.<p>
  _  */
  _ protected_A_CmsXmlValueCdataBase() {

   _  _ super();
_  _}

    /**
 _  _* Initializes the required members for_this_XML content value.<p>
___ _*
  __ *_@param_document the XML content instance this_value_belongs to
     *_@param element the XML_element_that contains this value
_    *_@param locale the locale this value_is created_for
 _   * @param type the type instance to create_the value for
   _ */
  _ protected_A_CmsXmlValueCdataBase(
_  __ _ I_CmsXmlDocument document,
    _ _ Element element,
   _   _Locale_locale,
     _  I_CmsXmlSchemaType type) {

 _    __super(document,_element, locale, type);
  _     m_stringValue_= element.getText();
 _  }

    /**
__   * Initializes the_schema_type descriptor values for this type_descriptor.<p>
__   *
 _   * @param name_the name of the XML node containing the value_according to the_XML schema
   __*_@param minOccurs minimum number of occurrences of this type according_to the_XML schema
 _   * @param maxOcc