Classes | |
struct | ScanRange |
The scan range used for mdlScanCriteria. More... | |
Typedefs | |
typedef struct Bentley::DgnPlatform::ScanRange | ScanRange |
The scan range used for mdlScanCriteria. More... | |
typedef int(* | ScanFunc_EachElement )(MSElementDescrP edP, CallbackArgP arg) |
Callback function used by mdlScan_extended. More... | |
Functions | |
int | mdlScan_file (void *outBuff, int *returnSize, int buffSize, unsigned long *filePos) |
mdlScan_file scans the design file according to the criteria established in the last call to mdlScan_initialize. More... | |
void | mdlScan_initScanlist (ExtScanListP scanlist) |
The mdlScan_initScanlist function initializes a MicroStation scan list pointed to by scanlist for subsequent calls to mdlScan_file. More... | |
int | mdlScan_initialize (DgnModelRefP modelRef, ExtScanListP scanListP) |
Load a scan list to the MicroStation design file scanner for subsequent calls to mdlScan_file. More... | |
void | mdlScan_noRangeCheck (ExtScanListP scanlist) |
The MicroStation design file scanning utility mdlScan_file is used for several purposes. More... | |
void | mdlScan_setDrawnElements (ExtScanListP scanlist) |
The MicroStation design file scanning utility mdlScan_file is used for several purposes. More... | |
void | mdlScan_singleViewClass (ExtScanListP scanlist, int viewIndex) |
The MicroStation design file scanning utility mdlScan_file is used for several purposes. More... | |
void | mdlScan_viewRange (ExtScanListP scanlist, int view, DgnModelRefP modelRef) |
mdlScan_viewRange sets the range members of the scan list pointed to by scanlist (scanlist->xlowlim, scanlist->xhighlim, scanlist->ylowlim, scanlist->yhighlim, scanlist->zlowlim, scanlist->zhighlim) to find only elements in view viewNumber and from file fileNumber. More... | |
int | mdlScan_extended (void *scanBuf, int *scanSize, UInt32 *eosFilePos, ScanFunc_EachElement iteratorFunc, CallbackArgP iteratorArg) |
mdlScan_extended provides the same functionality as the mdlScan_file function, but also provides the ability for the application program to receive control after each element which meets the scanning criteria instead of waiting for the scanner to return the information after each call. More... | |
int | mdlScanCriteria_setModel (ScanCriteriaP scP, DgnModelRefP modelRef) |
Sets the model on which the scan criteria will work. More... | |
DgnModelRefP | mdlScanCriteria_getModel (ScanCriteriaP scP) |
Returns the model on which the scan criteria will work. More... | |
StatusInt | mdlScanCriteria_setReferenceFile (ScanCriteriaP scP, DgnAttachmentP pRef) |
Alternative to mdlScanCriteria_setModel to set the scanned file directly from a reference file structure. More... | |
int | mdlScanCriteria_setReturnType (ScanCriteriaP scP, int returnType, int oneElementOnly, int nestCells) |
The mdlScanCriteria_setReturnType function is used to establish the type of information that should be returned by the scan operation. More... | |
StatusInt | mdlScanCriteria_setElmDscrCallback (ScanCriteriaP scP, PFScanElemDscrCallback callbackFunc, CallbackArgP callbackArg) |
Setup a per-descriptor callback function for scan results. More... | |
int | mdlScanCriteria_scanAllModelsOfFile (ScanCriteriaP inScP, PFScanElemDscrCallback pCallbackFunc, CallbackArgP pCallbackArg, DgnPlatform::DgnModelSections modelSections, DgnFileP pDgnFileObj) |
Iterates through all models of a given file, scanning each in turn. More... | |
StatusInt | mdlScanCriteria_setElemRefCallback (ScanCriteriaP scP, PFScanElemRefCallback callbackFunc, CallbackArgP callbackArg) |
Setup an ElementRefP callback function for scan results. More... | |
int | mdlScanCriteria_setRangeTest (ScanCriteriaP scP, DgnPlatform::ScanRange *srP) |
The mdlScanCriteria_setRangeTest function is used to set the range for the scan operation. More... | |
int | mdlScanCriteria_setAttributeTest (ScanCriteriaP scP, int entity, long occurrence, ExtendedAttrBuf *extAttrBuf) |
The mdlScanCriteria_setAttributeTest function is used to enable or disable various attribute tests. More... | |
int | mdlScanCriteria_setPriorityTest (ScanCriteriaP scP, UInt32 minPriority, UInt32 maxPriority) |
The mdlScanCriteria_setPriorityTest function is used to enable or disable priority testing with min and max limits. More... | |
int | mdlScanCriteria_setTimeTest (ScanCriteriaP scP, double minModTime, double maxModTime) |
The mdlScanCriteria_setTimeTest function is used to enable or disable the testing of modification time with minimum and maximum time limits. More... | |
int | mdlScanCriteria_setElementTypeTest (ScanCriteriaP scP, UShort *typeMask, int maskSize) |
The mdlScanCritiera_setElementTypeTest function is used to enable or disable testing based on element type. More... | |
int | mdlScanCriteria_getElementTypeMask (ScanCriteriaP scP, UShort *typeMask, int maskSize) |
The mdlScanCriteria_getElementTypeMask function is used to retrieve the current element type mask from the scan criteria. More... | |
int | mdlScanCriteria_getElementTypeMaskSize (ScanCriteriaP scP, int *maskSize) |
Gets the size of the element type mask from the specified DgnPlatform::ScanCriteria. More... | |
int | mdlScanCriteria_setDrawnElements (ScanCriteriaP scP) |
The mdlScanCriteria_setDrawnElements function is used to limit the scan operation to drawn elements, eliminating control elements from the scan process. More... | |
int | mdlScanCriteria_setCellNameTest (ScanCriteriaP scP, WCharCP cellName) |
The mdlScanCriteria_setCellNameTest function is used to establish the name of a cell as the target for the scan operation. More... | |
int | mdlScanCriteria_setLevelTest (ScanCriteriaP scP, BitMaskP levelBitMask, bool enableMultiLevelTest, bool freeWhenDone) |
The mdlScanCriteria_setLevelTest function is used to set a level bit mask for the scan operation. More... | |
BitMaskCP | mdlScanCriteria_getLevelBitMask (ScanCriteriaCP scP) |
The mdlScanCriteria_getLevelBitMask function is used to get the level bit mask from the scan criteria. More... | |
int | mdlScanCriteria_setConstLevelTest (ScanCriteriaP scP, BitMaskCP levelBitMask, bool enableMultiLevelTest) |
The mdlScanCriteria_setConstLevelTest function is used to set a level bit mask for the scan with a "const" bit mask. More... | |
int | mdlScanCriteria_setPropertiesTest (ScanCriteriaP scP, int propertiesVal, int propertiesMask) |
The mdlScanCriteria_setPropertiesTest function is used to enable or disable testing by property value and mask. More... | |
int | mdlScanCriteria_getProperties (ScanCriteriaP scP, int *propertiesValP, int *propertiesMaskP) |
The mdlScanCriteria_getProperties function is used to get the properties value and mask data from the specified scan criteria structure. More... | |
StatusInt | mdlScanCriteria_setLockedTest (ScanCriteriaP scP, bool lockedTest, bool lockedValue) |
The mdlScanCriteria_setLockedTest function is used to enable or disable testing based on the locked status of the design file elements. More... | |
int | mdlScanCriteria_setClassTest (ScanCriteriaP scP, int classMask) |
The mdlScanCriteria_setClassTest function is used to enable or disable the testing of element class. More... | |
int | mdlScanCriteria_setClassTestFromView (ScanCriteriaP scP, int viewIndex) |
The mdlScanCriteria_setClassTestFromView function is used to enable or disable the test of element class derived from view flags. More... | |
int | mdlScanCriteria_getClassMask (ScanCriteriaCP scP) |
The mdlScanCriteria_getClassMask function is used to get the current class mask. More... | |
int | mdlScanCriteria_setGraphicGroupTest (ScanCriteriaP scP, UInt32 graphicGroup) |
The mdlScanCriteria_setGraphicGroupTest function is used to enable or disable scanning on graphic group. More... | |
int | mdlScanCriteria_setStartFilePos (ScanCriteriaP scP, UInt32 startFilePos) |
The mdlScanCriteria_setStartFilePos function is used to set the file position in the design file to be scanned at which the scan operation will begin. More... | |
int | mdlScanCriteria_setStopFilePos (ScanCriteriaP scP, UInt32 stopFilePos) |
The mdlScanCriteria_setStopFilePos function is used to set the file position at which the scan operation will stop. More... | |
int | mdlScanCriteria_setSkewRangeTest (ScanCriteriaP scP, DgnPlatform::ScanRange *mainRangeP, DgnPlatform::ScanRange *skewRangeP, DPoint3dP skewVectorP) |
The mdlScanCriteria_setSkewRangeTest function is used to set up a skew range test for the scan operation. More... | |
int | mdlScanCriteria_setExtendedRangeTest (ScanCriteriaP scP, DgnPlatform::ScanRange *srP, int rangeNum) |
The mdlScanCriteria_setExtendedRangeTest function is used to enable or disable one of the array of test ranges. More... | |
int | mdlScanCriteria_getExtendedRangeTest (ScanCriteriaP scP, DgnPlatform::ScanRange *srP, int rangeNum) |
The mdlScanCriteria_getExtendedRangeTest function is used to retrieve one of the array of test ranges. More... | |
StatusInt | mdlScanCriteria_setViewTest (ScanCriteriaP scanCriteriaP, int viewIndex, DgnModelRefP modelRef) |
The mdlScanCriteria_setViewTest function is used to set the specified scan criteria to scan for the levels, class file and model that are displayable for the specified file in the specified view based on the current display flags, displayed levels and view model. More... | |
StatusInt | mdlScanCriteria_setViewTestWithTypeMask (ScanCriteriaP scanCriteriaP, int viewIndex, DgnModelRefP modelRef, UShort *typeMask, int maskSize, Int16 propmsk, Int16 propval, bool setLockedTest, Int16 noLocked) |
Used to set the specified scan criteria to scan for the levels, class file and model that are displayable for the specified file in the specified view based on the current display flags, displayed levels and view model. More... | |
StatusInt | mdlScanCriteria_setViewRangeTest (ScanCriteriaP scanCriteriaP, int viewIndex, DgnModelRefP modelRef) |
The mdlScanCriteria_setViewRangeIndex function is used to set the scan criteria range test to contain the contents of the specified model within the given view. More... | |
StatusInt | mdlScanCriteria_setViewNpcRangeTest (ScanCriteriaP scanCriteria, int viewIndex, DgnModelRefP modelRef, DRange3dCP npcRange) |
The mdlScanCriteria_setViewRangeIndex function is used to set the scan criteria range test to contain the contents of the specified model within the given view. More... | |
StatusInt | mdlScanCriteria_setViewLevelTest (ScanCriteriaP scanCriteriaP, int viewIndex, DgnModelRefP modelRef) |
Set the scan criteria level test to contain the contents of the given model within a given view. More... | |
ScanCriteriaP | mdlScanCriteria_createFindNextCriteria (DgnModelRefP modelRef, UInt32 filePos) |
The mdlScanCriteria_createFindNextCriteria function is used to create a scanCriteria returning element data, set its file to the specified file at the specified file position. More... | |
ScanCriteriaP | mdlScanCriteria_createAllGGCriteria (DgnModelRefP modelRef, int ggroup) |
The mdlScanCriteria_createAllGGCriteria function is used to create a scanCriteria returning file position and data of the elements in the specified graphic group within the specified model. More... | |
StatusInt | mdlScanCriteria_setLocateTest (ScanCriteriaP scanCriteriaP, bool setLockedTest) |
The mdlScanCriteria_setLocateTest function is used to set the scan criteria to scan for the types and properties that are enabled in the current locate table. More... | |
void | mdlScanCriteria_setDisplaySetTest (ScanCriteriaP scanCriteriaP, bool enable) |
Description Turns on or off the test of whether a particular element is in the display set. More... | |
void | mdlScanCriteria_setIncludedTest (ScanCriteriaP scanCriteriaP, bool enable) |
Turns on or off the test of whether a particular elements in included in the display for a reference. More... | |
int | mdlScanCriteria_addSingleElementTypeTest (ScanCriteriaP scP, int type) |
The mdlScanCriteria_addSingleElementTestType function is used to set the scan to return elements of the type specified. More... | |
int | mdlScanCriteria_removeSingleElementTypeTest (ScanCriteriaP scP, int typeTest) |
The mdlScanCriteria_removeSingleElementTypeTest function is used to remove the given element type from the mask of those returned by the scan. More... | |
int | mdlScanCriteria_addSingleLevelTest (ScanCriteriaP scP, int level) |
The mdlScanCriteria_addSingleLevelTest is used to set the scan to return elements from the specified level. More... | |
bool | mdlScanCriteria_isLevelActive (ScanCriteriaP scP, int level) |
The mdlScanCriteria_isLevelActive function is used to determine whether the specified level is active in the specified scan. More... | |
bool | mdlScanCriteria_isClassActive (ScanCriteriaP scP, int dgnClass) |
The mdlScanCriteria_isClassActive function is used to determine whether the specified element class is active in the specified scan. More... | |
void | mdlScanCriteria_setNestOverride (ScanCriteriaP scP, short *mask, bool operation) |
The mdlScanCriteria_setNestOverride function is used to set or clear the scan criteria to override nesting to return all components if override is true for type. More... | |
void | mdlScanCriteria_disableBsplineComponents (ScanCriteriaP scP) |
The mdlScanCriteria_disableBsplineComponents function is used to restrict the specified scanCriteria so that it will not return Bspline curve or surface component elements. More... | |
void | mdlScanCriteria_setModelSections (ScanCriteriaP scP, DgnPlatform::DgnModelSections modelSections) |
The mdlScanCriteria_setModelSections function is used to set the model sections or sections that are the target of the scan operation specified by the scan criteria. More... | |
void | mdlScanCriteria_setFilterFunction (ScanCriteriaP scP, PFScanFilterFunction filterFunc, CallbackArgP filterArg, PFFilterArgFreeFunction argFreeFunc) |
UInt32 | mdlScanCriteria_getCurrentFilePos (ScanCriteriaP scP) |
The mdlScanCriteria_getCurrentFilePos function is used to get the current file position of the scan operation. More... | |
typedef int(* ScanFunc_EachElement)(MSElementDescrP edP, CallbackArgP arg) |
Callback function used by mdlScan_extended.
[in] | edP | current element |
[in] | arg | arg provided by caller |
typedef struct Bentley::DgnPlatform::ScanRange ScanRange |
The scan range used for mdlScanCriteria.
int mdlScan_extended | ( | void * | scanBuf, |
int * | scanSize, | ||
UInt32 * | eosFilePos, | ||
ScanFunc_EachElement | iteratorFunc, | ||
CallbackArgP | iteratorArg | ||
) |
mdlScan_extended provides the same functionality as the mdlScan_file
function, but also provides the ability for the application program to receive control after each element which meets the scanning criteria instead of waiting for the scanner to return the information after each call.
That is, the complete file can be scanned in a single call to this function.
[out] | scanBuf | output buffer |
[in,out] | scanSize | size of buffer, num words returned |
[out] | eosFilePos | file position where we stopped scanning |
[in] | iteratorFunc | function called for each accepted element |
[in] | iteratorArg | argument passed to iteratorFunc |
Value | Reason |
---|---|
10 | End of file reached (END_OF_DGN). |
11 | scanBuffer full before end of file, (BUFF_FULL). |
65 | Bad file number. |
66 | Physical end of file encountered before MicroStation end of file mark. |
67 | Improper scan list. |
68 | Invalid element encountered. |
int mdlScan_file | ( | void * | outBuff, |
int * | returnSize, | ||
int | buffSize, | ||
unsigned long * | filePos | ||
) |
mdlScan_file scans the design file according to the criteria
established in the last call to mdlScan_initialize.
When the scan completes, *filepos is set to the start of the next element in the file.
[out] | outBuff | accepted data |
[out] | returnSize | amount of information in scanBuffer |
[in] | buffSize | size of scanBuffer |
[out] | filePos | ending file position |
Value | Meaning |
---|---|
10 | End of file reached, (END_OF_DGN). |
11 | scanBuffer full before end of file, (BUFF_FULL). |
65 | Bad file number. |
66 | Physical end of file encountered before MicroStation end of file mark. |
67 | Improper scan list. |
68 | Invalid element encountered. |
int mdlScan_initialize | ( | DgnModelRefP | modelRef, |
ExtScanListP | scanListP | ||
) |
Load a scan list to the MicroStation design file scanner for subsequent calls to mdlScan_file.
This function is obsolete and remains only for backward compatability. New devlopment should use the mdlScanCriteria_* functions.
[in] | modelRef | The model to be scanned. | ||||||||||||||||||||||||||||||
[in] | scanListP | The scan criteria to be used. Scanlist is a structure defined in scanner.h. It consists of members that determine elements that are returned in subsequent calls to mdlScan_file. The meanings of the members are as follows:
|
void mdlScan_initScanlist | ( | ExtScanListP | scanlist | ) |
The mdlScan_initScanlist function initializes a MicroStation scan
list pointed to by scanlist for subsequent calls to mdlScan_file.
The scan list is zeroed and the scan list length member is set to the proper size.
[in] | scanlist | scan list |
void mdlScan_noRangeCheck | ( | ExtScanListP | scanlist | ) |
The MicroStation design file scanning utility mdlScan_file is used
for several purposes.
mdlScan_setDrawnElements, mdlScan_singleViewClass, mdlScan_noRangeCheck and mdlScan_viewRange ease the task of establishing scan criteria. mdlScan_noRangeCheck sets the range members of the scan list pointed to by scanlist (scanlist->xlowlim, scanlist->xhighlim, scanlist->ylowlim, scanlist->yhighlim, scanlist->zlowlim, scanlist->zhighlim) so that the scan list encompasses the entire design cube. When this scan list is used in subsequent calls to mdlScan_file, no elements are rejected based on range criteria. Since the scanner always checks element ranges, make sure you call mdlScan_noRangeCheck if you do want to accept elements regardless of their range. scanlist->yhighlim, scanlist->zlowlim, scanlist->zhighlim) to find only elements in view viewNumber and from file fileNumber.
[in] | scanlist | scan list |
void mdlScan_setDrawnElements | ( | ExtScanListP | scanlist | ) |
The MicroStation design file scanning utility mdlScan_file is used
for several purposes.
mdlScan_setDrawnElements, mdlScan_singleViewClass, mdlScan_noRangeCheck and mdlScan_viewRange ease the task of establishing scan criteria. mdlScan_setDrawnElements sets the type mask member scanlist->typmask so the scan list returns displayable elements when used in subsequent calls to mdlScan_file. The ELEMTYPE bit in scanlist->scantype must be set to cause the scanner to check element types.
[in] | scanlist | scan list |
void mdlScan_singleViewClass | ( | ExtScanListP | scanlist, |
int | viewIndex | ||
) |
The MicroStation design file scanning utility mdlScan_file is used
for several purposes.
mdlScan_setDrawnElements, mdlScan_singleViewClass, mdlScan_noRangeCheck and mdlScan_viewRange ease the task of establishing scan criteria. mdlScan_singleViewClass sets the class mask member of the scan list pointed to by scanlist (scanlist->clasmsk) so that subsequent calls to mdlScan_file return only the element classes that currently display in view viewNumber. The PROPCLAS bit in scanlist->scantype must be set to cause the scanner to check element class.
[in] | scanlist | scan list |
[in] | viewIndex | view to scan |
void mdlScan_viewRange | ( | ExtScanListP | scanlist, |
int | view, | ||
DgnModelRefP | modelRef | ||
) |
mdlScan_viewRange sets the range members of the scan list pointed
to by scanlist (scanlist->xlowlim, scanlist->xhighlim, scanlist->ylowlim, scanlist->yhighlim, scanlist->zlowlim, scanlist->zhighlim) to find only elements in view viewNumber and from file fileNumber.
[in] | scanlist | scan list |
[in] | view | view to scan |
[in] | modelRef | file to scan |
int mdlScanCriteria_addSingleElementTypeTest | ( | ScanCriteriaP | scP, |
int | type | ||
) |
The mdlScanCriteria_addSingleElementTestType function is used to set the scan
to return elements of the type specified.
[in] | scP | is the scan criteria structure. |
[in] | type | is the target element type to scan for. |
int mdlScanCriteria_addSingleLevelTest | ( | ScanCriteriaP | scP, |
int | level | ||
) |
The mdlScanCriteria_addSingleLevelTest is used to set the scan
to return elements from the specified level.
[in] | scP | is the scan criteria structure. |
[in] | level | is the target level to scan for. |
ScanCriteriaP mdlScanCriteria_createAllGGCriteria | ( | DgnModelRefP | modelRef, |
int | ggroup | ||
) |
The mdlScanCriteria_createAllGGCriteria function is used to create a
scanCriteria returning file position and data of the elements in the specified graphic group within the specified model.
The caller is responsible for calling mdlScanCriteria_free to free the scanCriteria after its use.
[in] | modelRef | indicates the model to scan. |
[in] | ggroup | is the graphic group number for which the scanCriteria will be set to scan. |
ScanCriteriaP mdlScanCriteria_createFindNextCriteria | ( | DgnModelRefP | modelRef, |
UInt32 | filePos | ||
) |
The mdlScanCriteria_createFindNextCriteria function is used to create a
scanCriteria returning element data, set its file to the specified file at the specified file position.
The caller is responsible for calling mdlScanCriteria_free to free the scan criteria after use.
[in] | modelRef | specifies the model that the scanCriteria will be set to scan. |
[in] | filePos | is the position within the file where the scan will start. |
void mdlScanCriteria_disableBsplineComponents | ( | ScanCriteriaP | scP | ) |
The mdlScanCriteria_disableBsplineComponents function is used to restrict the
specified scanCriteria so that it will not return Bspline curve or surface component elements.
[in,out] | scP | is the scanCriteria to set the restriction on. |
int mdlScanCriteria_getClassMask | ( | ScanCriteriaCP | scP | ) |
The mdlScanCriteria_getClassMask function is used to get the current class mask.
[in,out] | scP | is the scan criteria on which the current class mask is set. |
UInt32 mdlScanCriteria_getCurrentFilePos | ( | ScanCriteriaP | scP | ) |
The mdlScanCriteria_getCurrentFilePos function is used to get the current file
position of the scan operation.
[in] | scP | is the scan criteria structure. |
int mdlScanCriteria_getElementTypeMask | ( | ScanCriteriaP | scP, |
UShort * | typeMask, | ||
int | maskSize | ||
) |
The mdlScanCriteria_getElementTypeMask function is used to retrieve the current
element type mask from the scan criteria.
[in] | scP | is the scan criteria from which the element type mask is retrieved. |
[out] | typeMask | is the element type mask retrieved from the scan criteria. |
[in] | maskSize | is the size of the type mask. |
int mdlScanCriteria_getElementTypeMaskSize | ( | ScanCriteriaP | scP, |
int * | maskSize | ||
) |
Gets the size of the element type mask from the specified DgnPlatform::ScanCriteria.
[in] | scP | points to the DgnPlatform::ScanCriteria |
[out] | maskSize | points to the size of the type mask |
int mdlScanCriteria_getExtendedRangeTest | ( | ScanCriteriaP | scP, |
DgnPlatform::ScanRange * | srP, | ||
int | rangeNum | ||
) |
The mdlScanCriteria_getExtendedRangeTest function is used to retrieve
one of the array of test ranges.
[in] | scP | is the scan criteria structure. |
[out] | srP | is the range criteria for rangeNum. |
[in] | rangeNum | is the index of this range. |
BitMaskCP mdlScanCriteria_getLevelBitMask | ( | ScanCriteriaCP | scP | ) |
The mdlScanCriteria_getLevelBitMask function is used to get the level bit mask
from the scan criteria.
[in] | scP | is the scan criteria to get the level bit mask from. |
DgnModelRefP mdlScanCriteria_getModel | ( | ScanCriteriaP | scP | ) |
Returns the model on which the scan criteria will work.
[in] | scP | points to the DgnPlatform::ScanCriteria to get the model from |
int mdlScanCriteria_getProperties | ( | ScanCriteriaP | scP, |
int * | propertiesValP, | ||
int * | propertiesMaskP | ||
) |
The mdlScanCriteria_getProperties function is used to get the properties value
and mask data from the specified scan criteria structure.
[in] | scP | is the scan criteria structure. |
[out] | propertiesValP | is the properties value. |
[out] | propertiesMaskP | is the properties mask. |
bool mdlScanCriteria_isClassActive | ( | ScanCriteriaP | scP, |
int | dgnClass | ||
) |
The mdlScanCriteria_isClassActive function is used to determine whether the
specified element class is active in the specified scan.
[in] | scP | is the scan criteria structure. |
[in] | dgnClass | is the element class to test. |
bool mdlScanCriteria_isLevelActive | ( | ScanCriteriaP | scP, |
int | level | ||
) |
The mdlScanCriteria_isLevelActive function is used to determine whether the
specified level is active in the specified scan.
[in] | scP | is the scan criteria structure. |
[in] | level | is the level to test. |
int mdlScanCriteria_removeSingleElementTypeTest | ( | ScanCriteriaP | scP, |
int | typeTest | ||
) |
The mdlScanCriteria_removeSingleElementTypeTest function is used to remove
the given element type from the mask of those returned by the scan.
[in] | scP | is the scan criteria structure. |
[in] | typeTest | is the element type to remove. |
int mdlScanCriteria_scanAllModelsOfFile | ( | ScanCriteriaP | inScP, |
PFScanElemDscrCallback | pCallbackFunc, | ||
CallbackArgP | pCallbackArg, | ||
DgnPlatform::DgnModelSections | modelSections, | ||
DgnFileP | pDgnFileObj | ||
) |
Iterates through all models of a given file, scanning each in turn.
The scan criteria tests are applied, including element category. The dictionary model elements are scanned only once as part of the first model. Only scan criteria with iterate return types are acceptable. The callback function can return SCANALL_ABORT_SCAN to abort the entire scan, or SCANALL_ABORT_CURRENT_MODEL to abort the scan of the current model. SUCCESS should be returned to continue scanning. Note that this function will load all models in the file, and as such should be avoided. Usually only visible elements are needed, so scanning the active model ref or loaded model refs using mdlDgnFileObj_traverseRootModelRefs is prefereable.
[in,out] | inScP | scan criteria and context |
[in] | pCallbackFunc | function to call for each element |
[in] | pCallbackArg | arg to callbackFunc |
[in] | modelSections | mask using DGNMODEL_SECTION_xxx |
[in] | pDgnFileObj | file to scan |
int mdlScanCriteria_setAttributeTest | ( | ScanCriteriaP | scP, |
int | entity, | ||
long | occurrence, | ||
ExtendedAttrBuf * | extAttrBuf | ||
) |
The mdlScanCriteria_setAttributeTest function is used to enable or disable
various attribute tests.
[in] | scP | is the scan criteria structure. |
[in] | entity | is the entity test value. If this is 0, the entity text is disabled. |
[in] | occurrence | is the occurrence test value. If this is 0, no occurrence test is performed. |
[in] | extAttrBuf | is a pointer to a structure of type ExtendedAttBuf, and provides a flexible mechanism for selecting elements based on their nongraphical attributes. The ExtendedAttBuf structure is defined as: The numWords member of this structure is set to the number of words in the attribute data that are to be considered at the beginning of each attribute linkage. The extAttData array specifies how the scanner is to test those numWords, which it does as follows: The first word of each attribute linkage is ANDed with extAttData[0] and the result compared with extAttData[numWords]. If the value matches, the check continues by ANDing the second word of the linkage with extAttData[1] and comparing with extAttData[numWords+1], etc. If the values for all numWords of any attribute linkage match, the element is accepted. Otherwise the element is rejected. If this argument is NULL, no extended attribute testing is done. |
int mdlScanCriteria_setCellNameTest | ( | ScanCriteriaP | scP, |
WCharCP | cellName | ||
) |
The mdlScanCriteria_setCellNameTest function is used to establish the name of a
cell as the target for the scan operation.
[in] | scP | is the scan criteria structure. |
[in] | cellName | is the name of the cell to set as the scan target. |
int mdlScanCriteria_setClassTest | ( | ScanCriteriaP | scP, |
int | classMask | ||
) |
The mdlScanCriteria_setClassTest function is used to enable or disable the
testing of element class.
If the classMask argument is set to 0, then class testing is disabled.
[in] | scP | is the scan criteria structure on which element class testing is enabled or disabled. |
[in] | classMask | is the mask of target classes. This is formed as an OR of the desired classes, using (1 << class) for the desired classes from the DgnElementClass enum. |
int mdlScanCriteria_setClassTestFromView | ( | ScanCriteriaP | scP, |
int | viewIndex | ||
) |
The mdlScanCriteria_setClassTestFromView function is used to enable or disable
the test of element class derived from view flags.
[in] | scP | is the scan criteria to set the class test on. |
[in] | viewIndex | indicates the view from which to derive the class mask. |
int mdlScanCriteria_setConstLevelTest | ( | ScanCriteriaP | scP, |
BitMaskCP | levelBitMask, | ||
bool | enableMultiLevelTest | ||
) |
The mdlScanCriteria_setConstLevelTest function is used to set a level bit mask
for the scan with a "const" bit mask.
In this case the level bit mask is never freed when the scan criteria is freed by calling mdlScanCriteria_free.
[in] | scP | is the scan criteria on which the level bit mask is set. |
[in] | levelBitMask | is the bit mask of acceptable levels. |
[in] | enableMultiLevelTest | is for a future capability and should always be set to false. |
void mdlScanCriteria_setDisplaySetTest | ( | ScanCriteriaP | scanCriteriaP, |
bool | enable | ||
) |
Description Turns on or off the test of whether a particular element is in the display set.
[in,out] | scanCriteriaP | is a pointer to the scan criteria to set display set testing for. |
[in] | enable | If true, only elements in the display set for the scan criteria's modelRef are returned by the scan. If false, elements are returned without regard to whether they are in the display set or not. |
int mdlScanCriteria_setDrawnElements | ( | ScanCriteriaP | scP | ) |
The mdlScanCriteria_setDrawnElements function is used to limit the scan
operation to drawn elements, eliminating control elements from the scan process.
[in] | scP | is the scan critiera structure. |
int mdlScanCriteria_setElementTypeTest | ( | ScanCriteriaP | scP, |
UShort * | typeMask, | ||
int | maskSize | ||
) |
The mdlScanCritiera_setElementTypeTest function is used to enable or disable
testing based on element type.
[in] | scP | is the scan criteria structure on which the typeMask is set. |
[in] | typeMask | is the element type bit mask. If this argument is NULL then all element types are scanned. |
[in] | maskSize | sets the size of the bit mask. |
StatusInt mdlScanCriteria_setElemRefCallback | ( | ScanCriteriaP | scP, |
PFScanElemRefCallback | callbackFunc, | ||
CallbackArgP | callbackArg | ||
) |
Setup an ElementRefP callback function for scan results.
[in] | scP | points to the DgnPlatform::ScanCriteria to set the callback function for |
[in] | callbackFunc | function pointer, called with parameter list callBackFunc (ElementRefP, void *callbackArg, ScanCriteriaP scP) |
[in] | callbackArg | caller's context data. |
StatusInt mdlScanCriteria_setElmDscrCallback | ( | ScanCriteriaP | scP, |
PFScanElemDscrCallback | callbackFunc, | ||
CallbackArgP | callbackArg | ||
) |
Setup a per-descriptor callback function for scan results.
The callback function is called once for each element descriptor that is accepted by the scan. The callback function should return SUCCESS to continue the scan or any other value to terminate the scan. If the scan is terminated by the callback function, the return code from mdlScanCriteria_scan is BUFF_FULL. The element descriptor that is passed to the callback function should not be modified or freed by the callback function. The callback function can duplicate the element descriptor, modify the duplicate, and then rewrite it to the file, if desired. The duplicate should then be freed, of course. If the callback function does modify and rewrite element descriptors, and the element descriptor might change size as a result of the modification, the programmer should take measures to make sure that the program doesn't later process that same element descriptor again, modifying it again and thus causing an infinite loop. The best way to do that is to make the scanner stop at the original EOF by using mdlScanCriteria_setStopFilePos.
[in] | scP | points to the DgnPlatform::ScanCriteria to set the callback function for |
[in] | callbackFunc | function pointer, called with parameter list callBackFunc (edP, callbackArg, DgnPlatform::ScanCriteria *scP) |
[in] | callbackArg | caller's context data. |
int mdlScanCriteria_setExtendedRangeTest | ( | ScanCriteriaP | scP, |
DgnPlatform::ScanRange * | srP, | ||
int | rangeNum | ||
) |
The mdlScanCriteria_setExtendedRangeTest function is used to enable or disable
one of the array of test ranges.
[in] | scP | is the scan criteria structure. |
[in] | srP | is the range criteria. |
[in] | rangeNum | is the index of this range. |
void mdlScanCriteria_setFilterFunction | ( | ScanCriteriaP | scP, |
PFScanFilterFunction | filterFunc, | ||
CallbackArgP | filterArg, | ||
PFFilterArgFreeFunction | argFreeFunc | ||
) |
[in,out] | scP | scan criteria for which filter function is set |
[in] | filterFunc | filter function |
[in] | filterArg | argument to f ilter function |
[in] | argFreeFunc | function to free filterArg when mdlScanCriteria_free is called |
int mdlScanCriteria_setGraphicGroupTest | ( | ScanCriteriaP | scP, |
UInt32 | graphicGroup | ||
) |
The mdlScanCriteria_setGraphicGroupTest function is used to enable or disable
scanning on graphic group.
If the graphicGroup argument is 0, the graphic group testing is disabled. If it is enabled, only elements with the given graphic group are returned.
[in] | scP | is the scan criteria structure on which graphic group testing is enabled or disabled. |
[in] | graphicGroup | is the target graphic group number to scan for. |
void mdlScanCriteria_setIncludedTest | ( | ScanCriteriaP | scanCriteriaP, |
bool | enable | ||
) |
Turns on or off the test of whether a particular elements in included in the display for a reference.
[in,out] | scanCriteriaP | is a pointer to the scan criteria to set reference include testing for. |
[in] | enable | If true, only elements in the included set for the scan criteria's modelRef are returned by the scan. If false, elements are returned without regard to whether they are in the included set or not. |
int mdlScanCriteria_setLevelTest | ( | ScanCriteriaP | scP, |
BitMaskP | levelBitMask, | ||
bool | enableMultiLevelTest, | ||
bool | freeWhenDone | ||
) |
The mdlScanCriteria_setLevelTest function is used to set a level bit mask for the
scan operation.
Optionally, the bitmask used to indicate the acceptable levels can be freed when the operation is complete.
[in] | scP | is the scan criteria structure. |
[in] | levelBitMask | is the bitmask indicating the acceptable levels. |
[in] | enableMultiLevelTest | is for a future capability and should always be set to false for V8. |
[in] | freeWhenDone | determines whether the bitmask is freed when the scan criteria is freed. |
StatusInt mdlScanCriteria_setLocateTest | ( | ScanCriteriaP | scanCriteriaP, |
bool | setLockedTest | ||
) |
The mdlScanCriteria_setLocateTest function is used to set the scan criteria to
scan for the types and properties that are enabled in the current locate table.
This should be used in conjunction with mdlScanCritiera_setViewTest to set up location within a view. No range testing is enabled.
[in,out] | scanCriteriaP | is a pointer to the scan criteria to set up to use the locate table types and properties for scanning. |
[in] | setLockedTest | determines whether locked elements will be eliminated during the scan. If this value is set to true and tcb->noLocked is also true, then locked elements will be filtered out. |
StatusInt mdlScanCriteria_setLockedTest | ( | ScanCriteriaP | scP, |
bool | lockedTest, | ||
bool | lockedValue | ||
) |
The mdlScanCriteria_setLockedTest function is used to enable or disable testing
based on the locked status of the design file elements.
[in] | scP | is the scan criteria structure on which the locked status testing is enabled or disabled. |
[in] | lockedTest | determines whether the locked status testing is enabled (true) or disabled (false). |
[in] | lockedValue | is the target locked flag value to scan for, either true or false. |
int mdlScanCriteria_setModel | ( | ScanCriteriaP | scP, |
DgnModelRefP | modelRef | ||
) |
Sets the model on which the scan criteria will work.
This resets the starting and ending file position, and sets the scan criteria to return all element categories.
[in] | scP | points to the DgnPlatform::ScanCriteria to set the model for |
[in] | modelRef | indicates the model to be scanned. |
void mdlScanCriteria_setModelSections | ( | ScanCriteriaP | scP, |
DgnPlatform::DgnModelSections | modelSections | ||
) |
The mdlScanCriteria_setModelSections function is used to set the model sections
or sections that are the target of the scan operation specified by the scan criteria.
Before this function is called, call mdlScanCriteria_setModel.
[in,out] | scP | is the scan criteria on which the element category is being set. |
[in] | modelSections | indicates the target sections for the scan. Valid values for the sections are OR'ed combinations of the DgnModelSections enum, except the combination DgnModelSections::Dictionary | DgnModelSections::GraphicElements is invalid. If mdlScanCriteria_setModelSections is not called, all model sections are scanned. |
void mdlScanCriteria_setNestOverride | ( | ScanCriteriaP | scP, |
short * | mask, | ||
bool | operation | ||
) |
The mdlScanCriteria_setNestOverride function is used to set or clear the scan
criteria to override nesting to return all components if override is true for type.
[in,out] | scP | is the scan criteria structure. |
[in] | mask | is the mask that determines which element types are set and which are not. |
[in] | operation | determines whether the mask is used to set or clear the nest override in the scan criteria structure. |
The mdlScanCriteria_setPriorityTest function is used to enable or disable
priority testing with min and max limits.
If maxPriority is less than minPriority, then priority testing is disabled.
[in] | scP | is the scan criteria structure. |
[in] | minPriority | is the minimum priority value. |
[in] | maxPriority | is the maximum priority value. |
int mdlScanCriteria_setPropertiesTest | ( | ScanCriteriaP | scP, |
int | propertiesVal, | ||
int | propertiesMask | ||
) |
The mdlScanCriteria_setPropertiesTest function is used to enable or disable
testing by property value and mask.
If the propertiesVal argument is set to 0, then properties testing is disabled.
[in] | scP | is the scan criteria structure on which property testing is enabled or disabled. |
[in] | propertiesVal | is the value part of the properties test. |
[in] | propertiesMask | is the mask part of the properties test. |
int mdlScanCriteria_setRangeTest | ( | ScanCriteriaP | scP, |
DgnPlatform::ScanRange * | srP | ||
) |
The mdlScanCriteria_setRangeTest function is used to set the range for the scan
operation.
Multiple ranges can be set using the mdlScanCriteria_setExtendedRangeTest function. The general range is index 0 of the array altered by the extended function.
[in] | scP | is the scan criteria structure on which the range is to be set. |
[in] | srP | is the scan range. If NULL, and no extended ranges have been set, range testing is disabled. |
StatusInt mdlScanCriteria_setReferenceFile | ( | ScanCriteriaP | scP, |
DgnAttachmentP | pRef | ||
) |
Alternative to mdlScanCriteria_setModel to set the scanned file directly from a reference file structure.
[in] | scP | points to the DgnPlatform::ScanCriteria to set the scanned file on |
[in] | pRef | points to the DgnPlatform::DgnAttachment structure to set the scanned file from |
int mdlScanCriteria_setReturnType | ( | ScanCriteriaP | scP, |
int | returnType, | ||
int | oneElementOnly, | ||
int | nestCells | ||
) |
The mdlScanCriteria_setReturnType function is used to establish the type of
information that should be returned by the scan operation.
[in] | scP | is the scan criteria structure containing the information about the scan operation. |
[in] | returnType | is one of the return type selectors. Valid values for this argument are: MSSCANCRIT_RETURN_FILEPOS MSSCANCRIT_RETURN_ELEMENTDATA MSSCANCRIT_RETURN_POSANDDATA MSSCANCRIT_RETURN_UNIQUEID MSSCANCRIT_ITERATE_ELMDSCR MSSCANCRIT_ITERATE_ELMREF |
[in] | oneElementOnly | indicates whether the scan operation should stop after a single element is found that matches the scan criteria. |
[in] | nestCells | enables/disables the return of complex elements (e.g. nested cells) that contain elements matching the scan criteria. Set this to false to disable the return of complete complex elements, set it to true to enable this feature. |
int mdlScanCriteria_setSkewRangeTest | ( | ScanCriteriaP | scP, |
DgnPlatform::ScanRange * | mainRangeP, | ||
DgnPlatform::ScanRange * | skewRangeP, | ||
DPoint3dP | skewVectorP | ||
) |
The mdlScanCriteria_setSkewRangeTest function is used to set up a skew range
test for the scan operation.
[in] | scP | is the scan criteria structure on which the skew range is set. |
[in] | mainRangeP | is the main range. |
[in] | skewRangeP | is the skew range. |
[in] | skewVectorP | is the skew vector to be applied. |
int mdlScanCriteria_setStartFilePos | ( | ScanCriteriaP | scP, |
UInt32 | startFilePos | ||
) |
The mdlScanCriteria_setStartFilePos function is used to set the file position in
the design file to be scanned at which the scan operation will begin.
[in] | scP | is the scan criteria structure on which the start file position is being set. |
[in] | startFilePos | is the file position in the target design file at which the scan operation will begin. |
int mdlScanCriteria_setStopFilePos | ( | ScanCriteriaP | scP, |
UInt32 | stopFilePos | ||
) |
The mdlScanCriteria_setStopFilePos function is used to set the file position at
which the scan operation will stop.
[in] | scP | is the scan criteria structure on which the stop file position is being set. |
[in] | stopFilePos | is the file position at which the scan operation will stop. |
int mdlScanCriteria_setTimeTest | ( | ScanCriteriaP | scP, |
double | minModTime, | ||
double | maxModTime | ||
) |
The mdlScanCriteria_setTimeTest function is used to enable or disable the
testing of modification time with minimum and maximum time limits.
If maxModTime is less than minModTime then modification time testing is disabled.
[in] | scP | is the scan critiera structure on which the modification time testing is enabled or disabled. |
[in] | minModTime | is the lower limit value of the time test range. |
[in] | maxModTime | is the upper limit value of the time test range. |
StatusInt mdlScanCriteria_setViewLevelTest | ( | ScanCriteriaP | scanCriteriaP, |
int | viewIndex, | ||
DgnModelRefP | modelRef | ||
) |
Set the scan criteria level test to contain the contents of the given model within a given view.
No other criteria are set.
[in,out] | scanCriteriaP | points to the DgnPlatform::ScanCriteria to set the level test on. |
[in] | viewIndex | the index of the view to copy the levelDisplayMask from |
[in] | modelRef | the modelRef for which the levelDisplayMask is found on the view. |
StatusInt mdlScanCriteria_setViewNpcRangeTest | ( | ScanCriteriaP | scanCriteria, |
int | viewIndex, | ||
DgnModelRefP | modelRef, | ||
DRange3dCP | npcRange | ||
) |
The mdlScanCriteria_setViewRangeIndex function is used to set the scan criteria range test to contain the contents of the specified model within the given view.
No other criteria are set.
[in,out] | scanCriteria | is the scan criteria to modify. |
[in] | viewIndex | is the view to get the range data from to set on the scan criteria. |
[in] | modelRef | is the model to scan. |
[in] | npcRange | fractional coordinates (lower left 000, upper right 111) of partial view. |
StatusInt mdlScanCriteria_setViewRangeTest | ( | ScanCriteriaP | scanCriteriaP, |
int | viewIndex, | ||
DgnModelRefP | modelRef | ||
) |
The mdlScanCriteria_setViewRangeIndex function is used to set the scan criteria range test to contain the contents of the specified model within the given view.
No other criteria are set.
[in,out] | scanCriteriaP | is the scan criteria to modify. |
[in] | viewIndex | is the view to get the range data from to set on the scan criteria. |
[in] | modelRef | is the model to scan. |
StatusInt mdlScanCriteria_setViewTest | ( | ScanCriteriaP | scanCriteriaP, |
int | viewIndex, | ||
DgnModelRefP | modelRef | ||
) |
The mdlScanCriteria_setViewTest function is used to set the specified scan
criteria to scan for the levels, class file and model that are displayable for the specified file in the specified view based on the current display flags, displayed levels and view model.
Element type test is set to display drawn elements. No range testing is enabled.
[in,out] | scanCriteriaP | is the scan criteria to configure. |
[in] | viewIndex | is the view within the design file to get the data from. |
[in] | modelRef | indicates the model to be scanned. |
StatusInt mdlScanCriteria_setViewTestWithTypeMask | ( | ScanCriteriaP | scanCriteriaP, |
int | viewIndex, | ||
DgnModelRefP | modelRef, | ||
UShort * | typeMask, | ||
int | maskSize, | ||
Int16 | propmsk, | ||
Int16 | propval, | ||
bool | setLockedTest, | ||
Int16 | noLocked | ||
) |
Used to set the specified scan criteria to scan for the
levels, class file and model that are displayable for the specified file in the specified view based on the current display flags, displayed levels and view model.
Element type test is set to display drawn elements unless a typeMask is specified. No range testing is enabled.
[in,out] | scanCriteriaP | is the scan criteria to configure. |
[in] | viewIndex | is the view within the design file to get the data from. |
[in] | modelRef | indicates the model to be scanned. |
[in] | typeMask | should be 8 UShorts (NULL for drawn elements) |
[in] | maskSize | size (bytes) of the typeMask buffer |
[in] | propmsk | properties mask |
[in] | propval | properties value |
[in] | setLockedTest | whether to set lock test based on noLocked |
[in] | noLocked | non-zero means don't allow selection of locked elements |