Aspose::Words::Markup::StructuredDocumentTagRangeStart Class Reference

Detailed Description

Represents a start of ranged structured document tag which accepts multi-sections content. See also StructuredDocumentTagRangeEnd.

#include <Aspose.Words.Cpp/Model/Markup/Sdt/StructuredDocumentTagRangeStart.h>

+ Inheritance diagram for Aspose::Words::Markup::StructuredDocumentTagRangeStart:

Public Member Functions

bool Accept (SharedPtr< DocumentVisitor > visitor) override
 Accepts a visitor. More...
 
int32_t get_Id ()
 Specifies a unique read-only persistent numerical Id for this SDT. More...
 
bool get_IsShowingPlaceholderText ()
 Specifies whether the content of this SDT shall be interpreted to contain placeholder text (as opposed to regular text contents within the SDT). if set to true, this state shall be resumed (showing placeholder text) upon opening this document. More...
 
MarkupLevel get_Level () const
 Gets the level at which this SDT range start occurs in the document tree. More...
 
bool get_LockContentControl ()
 When set to true, this property will prohibit a user from deleting this SDT. More...
 
bool get_LockContents ()
 When set to true, this property will prohibit a user from editing the contents of this SDT. More...
 
NodeType get_NodeType () const override
 Gets the type of this node. More...
 
SharedPtr< StructuredDocumentTagRangeEndget_RangeEnd ()
 Specifies end of range if the StructuredDocumentTag is a ranged structured document tag. Otherwise returns null. More...
 
SdtType get_SdtType ()
 Gets type of this Structured document tag. More...
 
String get_Tag ()
 Specifies a tag associated with the current SDT node. Can not be null. More...
 
String get_Title () const
 Specifies the friendly name associated with this SDT. Can not be null. More...
 
SharedPtr< XmlMappingget_XmlMapping ()
 Gets an object that represents the mapping of this structured document tag range to XML data in a custom XML part of the current document. More...
 
virtual const TypeInfoGetType () const override
 
virtual bool Is (const TypeInfo &target) const override
 
- Public Member Functions inherited from Node
SharedPtr< NodeClone (bool isCloneChildren)
 Creates a duplicate of the node. More...
 
virtual SharedPtr< DocumentBaseget_Document () const
 Gets the document to which this node belongs. More...
 
virtual bool get_IsComposite ()
 Returns true if this node can contain other nodes. More...
 
SharedPtr< Nodeget_NextSibling ()
 Gets the node immediately following this node. More...
 
SharedPtr< CompositeNodeget_ParentNode ()
 Gets the immediate parent of this node. More...
 
SharedPtr< Nodeget_PreviousSibling ()
 Gets the node immediately preceding this node. More...
 
SharedPtr< Rangeget_Range ()
 Returns a Range object that represents the portion of a document that is contained in this node. More...
 
SharedPtr< CompositeNodeGetAncestor (NodeType ancestorType)
 Gets the first ancestor of the specified NodeType. More...
 
template<typename T >
GetAncestorOf ()
 
virtual String GetText ()
 Gets the text of this node and of all its children. More...
 
SharedPtr< NodeNextPreOrder (SharedPtr< Node > rootNode)
 Gets next node according to the pre-order tree traversal algorithm. More...
 
SharedPtr< NodePreviousPreOrder (SharedPtr< Node > rootNode)
 Gets the previous node according to the pre-order tree traversal algorithm. More...
 
void Remove ()
 Removes itself from the parent. More...
 
String ToString (SaveFormat saveFormat)
 Exports the content of the node into a string in the specified format. More...
 
String ToString (SharedPtr< SaveOptions > saveOptions)
 Exports the content of the node into a string using the specified save options. More...
 
- Public Member Functions inherited from Object
ASPOSECPP_SHARED_API Object ()
 
ASPOSECPP_SHARED_API Object (Object const &x)
 
virtual ASPOSECPP_SHARED_API ~Object ()
 
virtual ASPOSECPP_SHARED_API bool Equals (ptr obj)
 
Detail::SmartPtrCounter * GetCounter ()
 
virtual ASPOSECPP_SHARED_API int GetHashCode () const
 
ASPOSECPP_SHARED_API void Lock ()
 
virtual ASPOSECPP_SHARED_API ptr MemberwiseClone () const
 
Objectoperator= (Object const &x)
 
bool ReferenceEquals (String const &str, std::nullptr_t)
 
bool ReferenceEquals (String const &str1, String const &str2)
 
int RemovedSharedRefs (int count)
 
virtual ASPOSECPP_SHARED_API void SetTemplateWeakPtr (unsigned int argument)
 
int SharedCount () const
 
ObjectSharedRefAdded ()
 
int SharedRefRemovedSafe ()
 
virtual ASPOSECPP_SHARED_API String ToString () const
 
ASPOSECPP_SHARED_API void Unlock ()
 
Detail::SmartPtrCounter * WeakRefAdded ()
 
void WeakRefRemoved ()
 

Static Public Member Functions

static const TypeInfoType ()
 
- Static Public Member Functions inherited from Node
static String NodeTypeToString (NodeType nodeType)
 A utility method that converts a node type enum value into a user friendly string. More...
 
static const TypeInfoType ()
 
- Static Public Member Functions inherited from Object
bool Equals (double const &objA, double const &objB)
 
bool Equals (float const &objA, float const &objB)
 
static std::enable_if<!IsSmartPtr< T1 >::value &&!IsSmartPtr< T2 >::value, bool >::type Equals (T1 const &objA, T2 const &objB)
 
static std::enable_if< IsSmartPtr< T1 >::value &&IsSmartPtr< T2 >::value, bool >::type Equals (T1 const &objA, T2 const &objB)
 
static bool ReferenceEquals (ptr const &objA, ptr const &objB)
 
static std::enable_if<!IsSmartPtr< T >::value, bool >::type ReferenceEquals (T const &objA, std::nullptr_t)
 
static std::enable_if<!IsSmartPtr< T >::value, bool >::type ReferenceEquals (T const &objA, T const &objB)
 
static const TypeInfoType ()
 

Additional Inherited Members

- Public Types inherited from Object
typedef SmartPtr< Objectptr
 
typedef System::Details::SharedMembersType shared_members_type
 

Member Function Documentation

◆ Accept()

bool Aspose::Words::Markup::StructuredDocumentTagRangeStart::Accept ( System::SharedPtr< Aspose::Words::DocumentVisitor visitor)
overridevirtual

Accepts a visitor.

Enumerates over this node and all of its children. Each node calls a corresponding method on DocumentVisitor.

For more info see the Visitor design pattern.

Parameters
visitorThe visitor that will visit the nodes.
Returns
True if all nodes were visited; false if DocumentVisitor stopped the operation before visiting all nodes.

Implements Aspose::Words::Node.

◆ get_Id()

int32_t Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_Id ( )

Specifies a unique read-only persistent numerical Id for this SDT.

Id attribute shall follow these rules:

  • The document shall retain SDT ids only if the whole document is cloned Clone.
  • During ImportNode() Id shall be retained if import does not cause conflicts with other SDT Ids in the target document.
  • If multiple SDT nodes specify the same decimal number value for the Id attribute, then the first SDT in the document shall maintain this original Id, and all subsequent SDT nodes shall have new identifiers assigned to them when the document is loaded.
  • During standalone SDT Clone() operation new unique ID will be generated for the cloned SDT node.
  • If Id is not specified in the source document, then the SDT node shall have a new unique identifier assigned to it when the document is loaded.

◆ get_IsShowingPlaceholderText()

bool Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_IsShowingPlaceholderText ( )

Specifies whether the content of this SDT shall be interpreted to contain placeholder text (as opposed to regular text contents within the SDT). if set to true, this state shall be resumed (showing placeholder text) upon opening this document.

◆ get_Level()

Aspose::Words::Markup::MarkupLevel Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_Level ( ) const

Gets the level at which this SDT range start occurs in the document tree.

◆ get_LockContentControl()

bool Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_LockContentControl ( )

When set to true, this property will prohibit a user from deleting this SDT.

◆ get_LockContents()

bool Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_LockContents ( )

When set to true, this property will prohibit a user from editing the contents of this SDT.

◆ get_NodeType()

Aspose::Words::NodeType Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_NodeType ( ) const
overridevirtual

Gets the type of this node.

Examples

Shows how to remove all nodes of a specific type from a composite node.

auto doc = MakeObject<Document>(MyDir + u"Tables.docx");
ASSERT_EQ(2, doc->GetChildNodes(Aspose::Words::NodeType::Table, true)->get_Count());
// Select the first child node in the body
SharedPtr<Node> curNode = doc->get_FirstSection()->get_Body()->get_FirstChild();
while (curNode != nullptr)
{
// Save the next sibling node as a variable in case we want to move to it after deleting this node
SharedPtr<Node> nextNode = curNode->get_NextSibling();
// A section body can contain Paragraph and Table nodes
// If the node is a Table, remove it from the parent
{
curNode->Remove();
}
// Continue going through child nodes until null (no more siblings) is reached
curNode = nextNode;
}
ASSERT_EQ(0, doc->GetChildNodes(Aspose::Words::NodeType::Table, true)->get_Count());

Shows how to enumerate immediate child nodes of a composite node using NextSibling.

auto doc = MakeObject<Document>(MyDir + u"Paragraphs.docx");
// Loop starting from the first child until we reach null
for (SharedPtr<Node> node = doc->get_FirstSection()->get_Body()->get_FirstChild(); node != nullptr; node = node->get_NextSibling())
{
// Output the types of the nodes that we come across
}

Implements Aspose::Words::Node.

◆ get_RangeEnd()

System::SharedPtr<Aspose::Words::Markup::StructuredDocumentTagRangeEnd> Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_RangeEnd ( )

Specifies end of range if the StructuredDocumentTag is a ranged structured document tag. Otherwise returns null.

◆ get_SdtType()

Aspose::Words::Markup::SdtType Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_SdtType ( )

Gets type of this Structured document tag.

◆ get_Tag()

System::String Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_Tag ( )

Specifies a tag associated with the current SDT node. Can not be null.

◆ get_Title()

System::String Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_Title ( ) const

Specifies the friendly name associated with this SDT. Can not be null.

◆ get_XmlMapping()

System::SharedPtr<Aspose::Words::Markup::XmlMapping> Aspose::Words::Markup::StructuredDocumentTagRangeStart::get_XmlMapping ( )

Gets an object that represents the mapping of this structured document tag range to XML data in a custom XML part of the current document.

◆ GetType()

virtual const System::TypeInfo& Aspose::Words::Markup::StructuredDocumentTagRangeStart::GetType ( ) const
overridevirtual

Reimplemented from Aspose::Words::Node.

◆ Is()

virtual bool Aspose::Words::Markup::StructuredDocumentTagRangeStart::Is ( const System::TypeInfo target) const
overridevirtual

Reimplemented from Aspose::Words::Node.

◆ Type()

static const System::TypeInfo& Aspose::Words::Markup::StructuredDocumentTagRangeStart::Type ( )
static
static ASPOSECPP_SHARED_API void WriteLine()
static System::String NodeTypeToString(Aspose::Words::NodeType nodeType)
A utility method that converts a node type enum value into a user friendly string.
@ Table
A Table object that represents a table in a Word document. A Table node can have Row nodes.
static std::enable_if< IsExceptionWrapper< T >::value, bool >::type Equals(const T &obj, const T2 &another)