All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.hfg.xml.msofficexml.docx.drawingml.DmlNonVisualShapeDrawingProperties Maven / Gradle / Ivy

There is a newer version: 20240423
Show newest version
package com.hfg.xml.msofficexml.docx.drawingml;


import com.hfg.xml.msofficexml.docx.Docx;
import com.hfg.xml.msofficexml.docx.wordprocessingml.WmlXMLTag;

public class DmlNonVisualShapeDrawingProperties extends WmlXMLTag
{
   private DmlNonVisualDrawingProperties      mDmlNonVisualDrawingProperties;
   private DmlNonVisualShapeProperties        mDmlNonVisualShapeProperties;

   //---------------------------------------------------------------------------
   public DmlNonVisualShapeDrawingProperties(Docx inDocx)
   {
      super(DmlXML.NON_VISUAL_SHAPE_DRAWING_PROPS, inDocx);
   }

   //---------------------------------------------------------------------------
   /**
    * Returns the non-visual drawing properties (<p:cNvPr>) tag if one exists or else instantiates a new one.
    * @return the non-visual drawing properties (<p:cNvPr>) tag
    */
   public DmlNonVisualDrawingProperties getNonVisualDrawingProperties()
   {
      if (null == mDmlNonVisualDrawingProperties)
      {
         // Check if it has been added via addSubtag()...
         mDmlNonVisualDrawingProperties = getOptionalSubtagByName(DmlXML.NON_VISUAL_DRAWING_PROPS);
         if (null == mDmlNonVisualDrawingProperties)
         {
            mDmlNonVisualDrawingProperties = new DmlNonVisualDrawingProperties();
            addSubtag(mDmlNonVisualDrawingProperties);
         }
      }

      return mDmlNonVisualDrawingProperties;
   }

   //---------------------------------------------------------------------------
   /**
    * Returns the non-visual shape properties (<p:cNvSpPr>) tag if one exists or else instantiates a new one.
    * @return the non-visual shape properties (<p:cNvSpPr>) tag
    */
   public DmlNonVisualShapeProperties getNonVisualShapeProperties()
   {
      if (null == mDmlNonVisualShapeProperties)
      {
         // Check if it has been added via addSubtag()...
         mDmlNonVisualShapeProperties = getOptionalSubtagByName(DmlXML.NON_VISUAL_SHAPE_PROPS);
         if (null == mDmlNonVisualShapeProperties)
         {
            mDmlNonVisualShapeProperties = new DmlNonVisualShapeProperties(getParentDoc());
            addSubtag(mDmlNonVisualShapeProperties);
         }
      }

      return mDmlNonVisualShapeProperties;
   }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy