Rhino C++ API  7.24
Public Member Functions | Static Public Member Functions | Public Attributes | Friends | List of all members
CRhinoInstanceDefinition Class Reference

#include <rhinoSdkInstance.h>

Inheritance diagram for CRhinoInstanceDefinition:
ON_InstanceDefinition ON_ModelComponent ON_Object

Public Member Functions

void DestroyRuntimeCache (bool bDelete=true) override
 
void Dump (ON_TextLog &text_log) const override
 virtual ON_Object::Dump override More...
 
bool GetBBox (double *boxmin, double *boxmax, bool bGrowBox=false) const
 
int GetContainers (ON_SimpleArray< const CRhinoInstanceDefinition * > &idef_list) const
 
int GetObjects (ON_SimpleArray< const CRhinoObject * > &objects) const
 
int GetReferences (ON_SimpleArray< const CRhinoInstanceObject * > &iref_object_list, int where_to_look=0) const
 
bool InUse (int where_to_look) const
 
bool IsInLinkedBlockReferenceModel () const
 
bool IsInWorksessionReferenceModel () const
 
bool IsTenuous () const
 
int NestedDefinitionUseCount (int other_idef_index) const
 
const CRhinoObjectObject (int index) const
 
int ObjectCount () const
 
bool RemoveLinetypeReference (int linetype_index)
 
unsigned int SizeOf () const override
 
int UsesDefinition (int other_idef_index) const
 
bool UsesLayer (int layer_index) const
 
bool UsesLinetype (int linetype_index) const
 
- Public Member Functions inherited from ON_InstanceDefinition
 ON_InstanceDefinition () ON_NOEXCEPT
 
 ON_InstanceDefinition (const ON_InstanceDefinition &)
 
 ~ON_InstanceDefinition ()
 
bool AddInstanceGeometryId (ON_UUID id)
 
const ON_BoundingBox BoundingBox () const
 
void ClearBoundingBox ()
 
void ClearInstanceGeometryIdList ()
 
void ClearLinkedFileContentHash ()
 
void ClearLinkedFileReference ()
 
void ClearLinkedFileRelativePath ()
 
void ClearLinkedIdefReferenceComponentSettings ()
 
const ON_SHA1_Hash ContentHash () const
 
const ON_wString Description () const
 
const ON_SHA1_Hash GeometryContentHash () const
 
bool HasLinkedIdefReferenceComponentSettings () const
 
ON_InstanceDefinition::IDEF_UPDATE_TYPE IdefUpdateType () const
 OBSOLETE - change IdefUpdateType() to InstanceDefinitionType() More...
 
ON_InstanceDefinition::IDEF_UPDATE_TYPE InstanceDefinitionType () const
 
const ON_SimpleArray< ON_UUID > & InstanceGeometryIdList () const
 
bool IsInstanceGeometryId (ON_UUID id) const
 
bool IsLinkedType () const
 
bool IsValid (class ON_TextLog *text_log=nullptr) const override
 
ON_InstanceDefinition::eLinkedComponentAppearance LinkedComponentAppearance () const
 
const ON_wStringLinkedFilePath () const
 
const ON_FileReference LinkedFileReference () const
 
const ON_ReferencedComponentSettingsLinkedIdefReferenceComponentSettings () const
 
ON_ReferencedComponentSettingsLinkedIdefReferenceComponentSettings (bool bCreateIfNonePresent)
 
ON::object_type ObjectType () const override
 
ON_InstanceDefinitionoperator= (const ON_InstanceDefinition &)
 
bool Read (ON_BinaryArchive &archive) override
 
bool RemoveInstanceGeometryId (int id_index)
 
bool RemoveInstanceGeometryId (ON_UUID id)
 
void SetBoundingBox (ON_BoundingBox bbox)
 
void SetDescription (const wchar_t *description)
 
bool SetInstanceDefinitionType (const ON_InstanceDefinition::IDEF_UPDATE_TYPE instance_definition_type)
 
void SetInstanceGeometryIdList (const ON_SimpleArray< ON_UUID > &instance_geometry_id_list)
 
bool SetLinkedComponentAppearance (ON_InstanceDefinition::eLinkedComponentAppearance linked_component_appearance)
 
bool SetLinkedFileReference (ON_InstanceDefinition::IDEF_UPDATE_TYPE linked_definition_type, const wchar_t *linked_file_full_path)
 
bool SetLinkedFileReference (ON_InstanceDefinition::IDEF_UPDATE_TYPE linked_definition_type, ON_FileReference linked_file_reference)
 
void SetSkipNestedLinkedDefinitions (bool bSkipNestedLinkedDefinitions)
 
void SetUnitSystem (const ON_UnitSystem &us)
 
void SetUnitSystem (ON::LengthUnitSystem us)
 
void SetURL (const wchar_t *url)
 
void SetURL_Tag (const wchar_t *url_tag)
 
bool SkipNestedLinkedDefinitions () const
 
const ON_UnitSystemUnitSystem () const
 
const ON_wString URL () const
 
const ON_wString URL_Tag () const
 
bool Write (ON_BinaryArchive &archive) const override
 
- Public Member Functions inherited from ON_ModelComponent
 ON_ModelComponent () ON_NOEXCEPT
 
 ON_ModelComponent (const ON_ModelComponent &source)
 
 ON_ModelComponent (ON_ModelComponent::Type component_type) ON_NOEXCEPT
 
 ON_ModelComponent (ON_ModelComponent::Type component_type, const ON_ModelComponent &source) ON_NOEXCEPT
 Locked status of source attributes is not copied to permit copy and modify operations. More...
 
 ~ON_ModelComponent ()=default
 
bool ChangeName (const wchar_t *new_name, class ON_ComponentManifest *manifest)
 
bool ClearComponentType ()
 
bool ClearId ()
 
bool ClearIndex ()
 
unsigned int ClearModelComponentAttributes (unsigned int attributes_filter)
 
bool ClearModelComponentStatus ()
 
bool ClearModelSerialNumber ()
 
bool ClearName ()
 
bool ClearParentId ()
 
int CompareName (const ON_UUID &other_parent_id, const wchar_t *other_name) const
 
int CompareName (const wchar_t *other_name) const
 
int CompareNameExact (const ON_UUID &other_parent_id, const wchar_t *other_name) const
 
int CompareNameExact (const wchar_t *other_name) const
 
ON_ModelComponent::Type ComponentType () const
 
bool ComponentTypeIsLocked () const
 
bool ComponentTypeIsSet () const
 
ON__UINT64 ContentVersionNumber () const
 
unsigned int CopyFrom (const ON_ModelComponent &src, unsigned int attributes_filter)
 
ON__UINT32 DataCRC (ON__UINT32 current_remainder) const override
 
const ON_wString DeletedName () const
 
const ON_NameHashDeletedNameHash () const
 
bool DeletedNameIsSet () const
 
bool DeleteName ()
 
bool EraseIdentification (bool bIgnoreLocks)
 
const wchar_tGetName (ON_wString &component_name) const
 
const ON_UUIDId () const
 
bool IdIsLocked () const
 
bool IdIsNil () const
 
bool IdIsNotNil () const
 
bool IdIsSet () const
 
const ON_UUIDIfIdIsNilSetId ()
 
int Index () const
 
int Index (int unset_index_value) const
 
bool IndexIsLocked () const
 
bool IndexIsSet () const
 
unsigned int InstanceDefinitionModelSerialNumber () const
 
bool IsDeleted () const
 
bool IsHidden () const
 
bool IsLocked () const
 
bool IsReferenceComponent () const
 
bool IsSystemComponent () const
 
bool IsValid (class ON_TextLog *text_log=nullptr) const override
 
void LockAllSettingsExceptName ()
 
void LockComponentType ()
 
void LockId ()
 
void LockIndex ()
 
void LockModelComponentStatus ()
 
void LockModelSerialNumber ()
 
void LockName ()
 
void LockParentId ()
 
ON_ComponentStatus ModelComponentStatus () const
 
bool ModelComponentStatusIsLocked () const
 
bool ModelComponentStatusIsSet () const
 
ON_UUID ModelObjectId () const override
 
unsigned int ModelSerialNumber () const
 
bool ModelSerialNumberIsLocked () const
 
bool ModelSerialNumberIsSet () const
 
const ON_wString Name () const
 
const wchar_tNameAsPointer () const
 
const ON_NameHashNameHash () const
 
bool NameIsEmpty () const
 
bool NameIsLocked () const
 
bool NameIsNotEmpty () const
 
bool NameIsSet () const
 
const ON_NameHash NewNameHash (const wchar_t *new_name) const
 
ON_ModelComponentoperator= (const ON_ModelComponent &source)
 
const ON_UUIDParentId () const
 
bool ParentIdIsLocked () const
 
bool ParentIdIsNil () const
 
bool ParentIdIsNotNil () const
 
bool ParentIdIsSet () const
 
bool ReadModelComponentAttributes (class ON_BinaryArchive &archive)
 
unsigned int ReferenceModelSerialNumber () const
 
ON__UINT64 RuntimeSerialNumber () const
 
const ON_UUIDSetAndLockId ()
 
bool SetAsSystemComponent ()
 
bool SetAsUnsetSystemComponent ()
 
bool SetComponentType (ON_ModelComponent::Type component_component_type)
 
bool SetDeletedModelComponentState (bool bDeleted, class ON_ComponentManifest *manifest)
 
void SetHiddenModelComponentState (bool bHidden)
 
const ON_UUIDSetId ()
 
bool SetId (const ON_UUID &component_id)
 
bool SetIdentification (const class ON_ComponentManifestItem &manifest_item, const wchar_t *manifest_name, bool bSetId, bool bParentId, bool bSetName, bool bSetIndex)
 
bool SetIndex (int component_index)
 
bool SetLocalizedSystemComponentName (const wchar_t *system_component_localized_name)
 
void SetLockedModelComponentState (bool bLocked)
 
bool SetModelComponentStatus (ON_ComponentStatus component_status)
 
bool SetModelSerialNumber (unsigned int model_serial_number)
 
bool SetModelSerialNumber (unsigned int model_serial_number, unsigned int reference_model_serial_number, unsigned int instance_definition_model_serial_number)
 
bool SetName (const wchar_t *component_name)
 
bool SetParentId (const ON_UUID &parent_id)
 
bool UndeleteName ()
 
bool WriteModelComponentAttributes (class ON_BinaryArchive &archive, unsigned int attributes_filter) const
 
- Public Member Functions inherited from ON_Object
 ON_Object () ON_NOEXCEPT
 
 ON_Object (const ON_Object &)
 
virtual ~ON_Object ()
 
virtual ON_AggregateComponentStatus AggregateComponentStatus () const
 
bool AttachUserData (class ON_UserData *pUserData)
 
unsigned int ClearAllComponentStates () const
 
virtual unsigned int ClearComponentStates (ON_COMPONENT_INDEX component_index, ON_ComponentStatus states_to_clear) const
 
virtual unsigned int ClearComponentStates (ON_ComponentStatus states_to_clear) const
 
void CopyUserData (const ON_Object &source_object)
 
unsigned int CopyUserData (const ON_Object &source_object, ON_UUID source_userdata_item_id, ON_Object::UserDataConflictResolution userdata_conflict_resolution)
 
virtual bool DeleteComponents (const ON_COMPONENT_INDEX *ci_list, size_t ci_count)
 
bool DetachUserData (class ON_UserData *pUserData)
 
void EmergencyDestroy ()
 
class ON_UserDataFirstUserData () const
 
virtual unsigned int GetComponentsWithSetStates (ON_ComponentStatus states_filter, bool bAllEqualStates, ON_SimpleArray< ON_COMPONENT_INDEX > &components) const
 
class ON_UserDataGetUserData (const ON_UUID &userdata_uuid) const
 
bool GetUserString (const wchar_t *key, ON_wString &string_value) const
 
int GetUserStringKeys (ON_ClassArray< ON_wString > &user_string_keys) const
 
int GetUserStrings (ON_ClassArray< ON_UserString > &user_strings) const
 
bool IsCorrupt (bool bRepair, bool bSilentError, class ON_TextLog *text_log) const
 
bool IsKindOf (const ON_ClassId *pClassId) const
 
virtual void MarkAggregateComponentStatusAsNotCurrent () const
 
virtual void MemoryRelocate ()
 
void MoveUserData (ON_Object &source_object)
 
unsigned int MoveUserData (ON_Object &source_object, ON_UUID source_userdata_item_id, ON_Object::UserDataConflictResolution userdata_conflict_resolution, bool bDeleteAllSourceItems)
 
ON_Objectoperator= (const ON_Object &)
 
void PurgeUserData ()
 
virtual unsigned int SetComponentStates (ON_COMPONENT_INDEX component_index, ON_ComponentStatus states_to_set) const
 
virtual unsigned int SetComponentStatus (ON_COMPONENT_INDEX component_index, ON_ComponentStatus status_to_copy) const
 
bool SetUserString (const wchar_t *key, const wchar_t *string_value)
 
int SetUserStrings (int count, const ON_UserString *user_strings, bool bReplace)
 
bool ThisIsNullptr (bool bSilentError) const
 
void TransformUserData (const class ON_Xform &xform)
 
virtual bool UpdateReferencedComponents (const class ON_ComponentManifest &source_manifest, const class ON_ComponentManifest &destination_manifest, const class ON_ManifestMap &manifest_map)
 
int UserStringCount () const
 

Static Public Member Functions

static unsigned int NextRuntimeSerialNumber ()
 
- Static Public Member Functions inherited from ON_InstanceDefinition
static const ON_InstanceDefinitionFromModelComponentRef (const class ON_ModelComponentReference &model_component_reference, const ON_InstanceDefinition *none_return_value)
 
static ON_InstanceDefinition::IDEF_UPDATE_TYPE InstanceDefinitionTypeFromUnsigned (unsigned int idef_type_as_unsigned)
 Converts and integer into an IDEF_UPDATE_TYPE enum. More...
 
static ON_InstanceDefinition::eLinkedComponentAppearance LinkedComponentAppearanceFromUnsigned (unsigned int linked_component_appearance_as_unsigned)
 
- Static Public Member Functions inherited from ON_ModelComponent
static int CompareId (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareIdAndName (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareName (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareNameAndId (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static int CompareNameExact (const ON_ModelComponent &a, const ON_ModelComponent &b)
 
static ON_ModelComponent::Type ComponentTypeFromUnsigned (unsigned int component_type_as_unsigned)
 
static bool ComponentTypeIsValid (ON_ModelComponent::Type component_type)
 
static bool ComponentTypeIsValidAndNotMixed (ON_ModelComponent::Type component_type)
 
static const ON_wString ComponentTypeToString (ON_ModelComponent::Type)
 
static bool IndexRequired (ON_ModelComponent::Type component_type)
 
static unsigned int Internal_SystemComponentHelper ()
 For internal use. Never call this function. More...
 
static const wchar_tIsNamePathSeparator (const wchar_t *s)
 
*static const wchar_tIsReferencePrefixDelimiter (const wchar_t *s)
 
static const wchar_tIsReferencePrefixSeparator (const wchar_t *s)
 
static bool IsValidComponentName (const class ON_ComponentManifest &model_manfest, const ON_ModelComponent &model_component, bool bPermitReferencePrefix, ON_wString &valid_name)
 
static bool IsValidComponentName (const ON_wString &candidate_component_name)
 
static bool IsValidComponentName (const wchar_t *candidate_component_name)
 
static bool IsValidComponentName (size_t length, const wchar_t *candidate_component_name)
 
static bool IsValidComponentNameFirstCodePoint (int length, const wchar_t *candidate_component_name)
 
static bool IsValidComponentNameFirstCodePoint (ON__UINT32 unicode_code_point)
 
static const ON_wString NameLeaf (const wchar_t *name)
 
static const ON_wString NameParent (const wchar_t *name, bool bIncludeReference)
 
static const ON_wString NameReferencePrefix (const wchar_t *name)
 
static ON__UINT64 NextRuntimeSerialNumber ()
 
static const ON_wString RemoveAllReferencePrefixDelimiters (const wchar_t *name)
 
static const ON_wString RemoveReferencePrefix (const wchar_t *name)
 
static const ON_wString RemoveTrailingNamePathSeparator (const wchar_t *name)
 
static const ON_wString RemoveTrailingReferencePrefixDelimiter (const wchar_t *name)
 
static const ON_wString RemoveTrailingReferencePrefixSeparator (const wchar_t *name)
 
static void SplitName (const wchar_t *name, ON_wString &reference_prefix, ON_wString &name_parent, ON_wString &name_leaf)
 
static bool UniqueNameIgnoresCase (ON_ModelComponent::Type component_type)
 
static bool UniqueNameIncludesParent (ON_ModelComponent::Type component_type)
 
static bool UniqueNameRequired (ON_ModelComponent::Type component_type)
 

Public Attributes

const unsigned int m_idef_runtime_sn
 runtime serial number More...
 
class CRhinoInstanceDefinitionTablem_idef_table
 
int m_remap_index = ON_UNSET_INT_INDEX
 Runtime index used when remapping for import/export. More...
 
int m_sort_index = ON_UNSET_INT_INDEX
 Runtime index used to sort these in the dialog. More...
 

Friends

class CRhinoDoc
 
class CRhinoInstanceDefinitionTable
 
class CRhinoInstanceObject
 
class CRhinoRead3dmHelper
 
class CRhInstanceDefinitionPrivate
 

Additional Inherited Members

- Public Types inherited from ON_InstanceDefinition
enum  {
  no_idef_settings = 0, idef_name_setting = 1, idef_description_setting = 2, idef_url_setting = 4,
  idef_units_setting = 8, idef_source_archive_setting = 0x10, idef_userdata_setting = 0x20, all_idef_settings = 0xFFFFFFFF
}
 
enum  eLinkedComponentAppearance : unsigned char { eLinkedComponentAppearance::Unset = 0, eLinkedComponentAppearance::Active = 1, eLinkedComponentAppearance::Reference = 2 }
 ON_InstanceDefinition::LinkedComponentStates specifies how model components (layers, materials, dimension styles, ...) from linked instance defintion files are appear in the active model. More...
 
enum  IDEF_UPDATE_TYPE : unsigned int { IDEF_UPDATE_TYPE::Unset = 0, IDEF_UPDATE_TYPE::Static = 1, IDEF_UPDATE_TYPE::LinkedAndEmbedded = 2, IDEF_UPDATE_TYPE::Linked = 3 }
 
- Public Types inherited from ON_ModelComponent
enum  Attributes : unsigned int {
  NoAttributes = 0U, ComponentSerialNumberAttribute = 0x0001U, TypeAttribute = 0x0002U, ModelSerialNumberAttribute = 0x0004U,
  IdAttribute = 0x0008U, IndexAttribute = 0x0010U, NameAttribute = 0x0020U, ParentIdAttribute = 0x0040U,
  DeletedNameAttribute = 0x0080U, ComponentStatusAttribute = 0x0100U, BinaryArchiveAttributes = 0x78U, AllAttributes = 0x1FFU,
  SystemComponentAttribute = 0x8000U
}
 
enum  Type : unsigned char {
  Type::Unset = 0, Type::Image = 1, Type::TextureMapping = 2, Type::RenderMaterial = 3,
  Type::LinePattern = 4, Type::Layer = 5, Type::Group = 6, Type::TextStyle = 7,
  Type::DimStyle = 8, Type::RenderLight = 9, Type::HatchPattern = 10, Type::InstanceDefinition = 11,
  Type::ModelGeometry = 12, Type::HistoryRecord = 13, Type::Mixed = 0xFE
}
 The ON_ModelComponent::Type enum has a value for each explicit component type and two special values, Unset and Mixed. Use an ON_ModelComponentTypeIterator instance to iterate over the ON_ModelComponent::Type values. /summary> More...
 
- Public Types inherited from ON_Object
enum  UserDataConflictResolution : unsigned char {
  UserDataConflictResolution::destination_object = 0, UserDataConflictResolution::source_object = 1, UserDataConflictResolution::source_copycount_gt = 2, UserDataConflictResolution::source_copycount_ge = 3,
  UserDataConflictResolution::destination_copycount_gt = 4, UserDataConflictResolution::destination_copycount_ge = 5, UserDataConflictResolution::delete_item = 6
}
 
- Static Public Attributes inherited from ON_InstanceDefinition
static const ON_InstanceDefinition Unset
 
- Static Public Attributes inherited from ON_ModelComponent
static const ON_wString NamePathSeparator
 
static const ON_wString ReferencePrefixDelimiter
 
static const ON_wString ReferencePrefixSeparator
 
static const ON_ModelComponent Unset
 
*static const ON_wString WorksessionReferencePrefix *const wchar_t
 
- Protected Member Functions inherited from ON_ModelComponent
void IncrementContentVersionNumber () const
 

Detailed Description

Copyright (c) 1993-2017 Robert McNeel & Associates. All rights reserved. Rhinoceros is a registered trademark of Robert McNeel & Associates.

THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.

For complete Rhino SDK copyright information see http://www.rhino3d.com/developer. Description: This is a list of the actual geometry that CRhinoInstanceObjects reference.

Member Function Documentation

◆ DestroyRuntimeCache()

void CRhinoInstanceDefinition::DestroyRuntimeCache ( bool  bDelete = true)
overridevirtual

Expert interface Description: Expert user function. If you are using openNURBS in its default configuration to read and write 3dm archives, you never need to call this function. Many objects employ lazy creation of (runtime) caches that save information to help speed geometric calculations. This function will destroy all runtime information. Parameters: bDelete - [in] if true, any cached information is properly deleted. If false, any cached information is simply discarded. This is useful when the cached information may be in alternate memory pools that are managed in nonstandard ways.

Reimplemented from ON_Object.

◆ Dump()

void CRhinoInstanceDefinition::Dump ( ON_TextLog text_log) const
overridevirtual

virtual ON_Object::Dump override

Reimplemented from ON_InstanceDefinition.

◆ GetBBox()

bool CRhinoInstanceDefinition::GetBBox ( double *  boxmin,
double *  boxmax,
bool  bGrowBox = false 
) const

◆ GetContainers()

int CRhinoInstanceDefinition::GetContainers ( ON_SimpleArray< const CRhinoInstanceDefinition * > &  idef_list) const

Description: Get a list of all the CRhinoInstanceDefinitions that contain a reference this instance definition. Parameters: idef_list - [out] Returns: number of objects added to the list. See Also: CRhinoInstanceDefinition::GetObjects

◆ GetObjects()

int CRhinoInstanceDefinition::GetObjects ( ON_SimpleArray< const CRhinoObject * > &  objects) const

Description: Get a list of the objects that belong to this instance definition. These objects are stored in the CRhinoDoc::m_instance_geometry list. Parameters: objects - [out] Returns: number of objects in list. See Also: CRhinoInstanceDefinition::GetReferences

◆ GetReferences()

int CRhinoInstanceDefinition::GetReferences ( ON_SimpleArray< const CRhinoInstanceObject * > &  iref_object_list,
int  where_to_look = 0 
) const

Description: Get a list of the CRhinoInstanceObjects (inserts) that contains a reference this instance definition. Parameters: iref_object_list - [out] where_to_look - [in] 0 = get top level references in active document The irefs returned in iref_object_list[] will have ->Attributes().Model() = ON::normal_object, ON::hidden_object, or ON::locked_object. 1 = get top level and nested references in active document The objects returned in iref_object_list[] will have ->Attributes().Model() = ON::normal_object, ON::hidden_object, or ON::locked_object. 2 = check for references from other instance definitions The objects returned in iref_object_list[] will have ->Attributes().Model() = ON::idef_object. Returns: number of objects added to the list. See Also: CRhinoInstanceDefinition::GetObjects Remarks: There are two separate lists of geometry objects, the model space

◆ InUse()

bool CRhinoInstanceDefinition::InUse ( int  where_to_look) const

Parameters: where_to_look - [in] 0 = check for top level references in active document 1 = check for top level and nested references in active document 2 = check for references in other instance definitions Returns: True if the instance definition is refereneced. See Also: CRhinoInstanceDefinition::GetReferences

◆ IsInLinkedBlockReferenceModel()

bool CRhinoInstanceDefinition::IsInLinkedBlockReferenceModel ( ) const

Returns True: This block definition is a sub-block in a linked block.

◆ IsInWorksessionReferenceModel()

bool CRhinoInstanceDefinition::IsInWorksessionReferenceModel ( ) const

Returns True: This block definition is from a worksession reference model.

◆ IsTenuous()

bool CRhinoInstanceDefinition::IsTenuous ( ) const

◆ NestedDefinitionUseCount()

int CRhinoInstanceDefinition::NestedDefinitionUseCount ( int  other_idef_index) const

Parameters: idef_index - [in] index of another instance definition Returns: Number of nested irefs that reference the "other" instance definition. Remarks: DefinitionUseCount( this->Index() ) returns 0.

◆ NextRuntimeSerialNumber()

static unsigned int CRhinoInstanceDefinition::NextRuntimeSerialNumber ( )
static

◆ Object()

const CRhinoObject* CRhinoInstanceDefinition::Object ( int  index) const

Parameters: index - [in] 0 <= index < ObjectCount() Returns: Pointer to an object used as part of this definition. Remarks: This returns an object that is used to define the geometry. This does NOT return an object that references this definition.count the number of references to this instance See Also: CRhinoInstanceDefinition::GetReferences CRhinoInstanceDefinition::GetObjects

◆ ObjectCount()

int CRhinoInstanceDefinition::ObjectCount ( ) const

Returns: Number of objects this definition uses. Remarks: This counts the objects that are used to define the geometry. This does NOT count the number of references to this instance definition. See Also: CRhinoInstanceDefinition::GetReferences CRhinoInstanceDefinition::GetObjects

◆ RemoveLinetypeReference()

bool CRhinoInstanceDefinition::RemoveLinetypeReference ( int  linetype_index)

Description: Change all of the objects in the block to use continuous linetype instead of the one in the linetype table at linetype_index Does not change layers referenced by the block even if they reference the linetype. Doesn't remove references to table[0] (continuous) Parameters: linetype_index - [in] index of linetype to search for Returns: true: success false: failure

◆ SizeOf()

unsigned int CRhinoInstanceDefinition::SizeOf ( ) const
overridevirtual

Returns: SizeOf this and the geometry definition objects used by this CRhinoInstanceDefinition.

Reimplemented from ON_InstanceDefinition.

◆ UsesDefinition()

int CRhinoInstanceDefinition::UsesDefinition ( int  other_idef_index) const

Description: Determine if this instance definition contains a reference to another instance definition. Parameters: other_idef_index - [in] index of another instance definition Returns: @untitled table 0 no 1 other_idef_index is the index of this instance definition >1 This CRhinoInstanceDefinition uses the instance definition and the returned value is the nesting depth.

◆ UsesLayer()

bool CRhinoInstanceDefinition::UsesLayer ( int  layer_index) const

Description: Returns true if some object in the instance defintion is on the layer with index layer_index. Parameters: layer_index - [in] index of layer to search for Returns: True if there is an object in the instance defintion that is on the layer.

◆ UsesLinetype()

bool CRhinoInstanceDefinition::UsesLinetype ( int  linetype_index) const

Description: Returns true if some object in the instance defintion references the linetype with index linetype_index. Parameters: linetype_index - [in] index of linetype to search for Returns: True if there is an object in the instance defintion that references that linetype.

Friends And Related Function Documentation

◆ CRhinoDoc

friend class CRhinoDoc
friend

◆ CRhinoInstanceDefinitionTable

friend class CRhinoInstanceDefinitionTable
friend

◆ CRhinoInstanceObject

friend class CRhinoInstanceObject
friend

◆ CRhinoRead3dmHelper

friend class CRhinoRead3dmHelper
friend

◆ CRhInstanceDefinitionPrivate

friend class CRhInstanceDefinitionPrivate
friend

Member Data Documentation

◆ m_idef_runtime_sn

const unsigned int CRhinoInstanceDefinition::m_idef_runtime_sn

runtime serial number

◆ m_idef_table

class CRhinoInstanceDefinitionTable& CRhinoInstanceDefinition::m_idef_table

◆ m_remap_index

int CRhinoInstanceDefinition::m_remap_index = ON_UNSET_INT_INDEX

Runtime index used when remapping for import/export.

◆ m_sort_index

int CRhinoInstanceDefinition::m_sort_index = ON_UNSET_INT_INDEX

Runtime index used to sort these in the dialog.