1SoMFPath(3IV)() SoMFPath(3IV)()
2
3
4
6 SoMFPath — multiple-value field containing any number of pointers to
7 paths
8
10 SoField > SoMField > SoMFPath
11
13 #include <Inventor/fields/SoMFPath.h>
14
15 Methods from class SoMFPath:
16
17 static SoType getClassTypeId()
18 virtual void getTypeId() const
19 SoPath * operator [](int i) const
20 const SoPath * * getValues(int start) const
21 int find(SoPath * targetValue, SbBool addIfNotFound =
22 FALSE)
23 void setValues(int start, int num, const SoPath * *newVal‐
24 ues)
25 void set1Value(int index, SoPath * newValue)
26 SoPath * operator =(SoPath * newValue)
27 void setValue(SoPath * newValue)
28 int operator ==(const SoMFPath &f) const
29 int operator !=(const SoMFPath &f) const
30 SoPath * * startEditing()
31 void finishEditing()
32
33 Methods from class SoMField:
34
35 int getNum() const
36 void setNum(int num)
37 virtual void deleteValues(int start, int num = -1)
38 virtual void insertSpace(int start, int num)
39 SbBool set1(int index, const char *valueString)
40 void get1(int index, SbString &valueString)
41
42 Methods from class SoField:
43
44 void setIgnored(SbBool ignore)
45 SbBool isIgnored() const
46 SbBool isDefault() const
47 virtual SbBool isOfType(SoType type) const
48 SbBool set(const char *valueString)
49 void get(SbString &valueString)
50 void touch()
51 SbBool connectFrom(SoField *fromField)
52 SbBool connectFrom(SoEngineOutput *fromEngine)
53 void disconnect()
54 SbBool isConnected() const
55 SbBool isConnectedFromField() const
56 SbBool getConnectedField(SoField *&writingField) const
57 SbBool isConnectedFromEngine() const
58 SbBool getConnectedEngine(SoEngineOutput *&engineOutput)
59 const
60 void enableConnection(SbBool flag)
61 SbBool isConnectionEnabled() const
62 int getForwardConnections(SoFieldList &list) const
63 SoFieldContainer * getContainer() const
64
65
67 This field maintains a set of pointers to SoPath instances, correctly
68 maintaining their reference counts.
69
70 SoMFPaths are written to file as one or more paths (see the SoPath man‐
71 ual page for a description of the file format for a path). When more
72 than one value is present, all of the values are enclosed in square
73 brackets and separated by commas.
74
76 static SoType getClassTypeId()
77 virtual void getTypeId() const
78 Returns the type for this class or a particular object of this
79 class.
80
81 SoPath * operator [](int i) const
82 Returns the i'th value of the field. Indexing past the end of the
83 field (passing in i greater than getNum()) will return garbage.
84
85 const SoPath * * getValues(int start) const
86 Returns a pointer into the array of values in the field, starting at
87 index start. The values are read-only; see the startEditing()/fin‐
88 ishEditing() methods for a way of modifying values in place.
89
90 int find(SoPath * targetValue, SbBool addIfNotFound =
91 FALSE)
92 Finds the given value in the array and returns the index of that
93 value in the array. If the value is not found, -1 is returned. If
94 addIfNotFound is set, then targetValue is added to the end of the
95 array (but -1 is still returned).
96
97 void setValues(int start, int num, const SoPath * *newVal‐
98 ues)
99 Sets num values starting at index start to the values in newValues.
100 The array will be automatically be made larger to accomodate the new
101 values, if necessary.
102
103 void set1Value(int index, SoPath * newValue)
104 Sets the index'th value in the array to newValue. The array will be
105 automatically expanded, if necessary.
106
107 SoPath * operator =(SoPath * newValue)
108 void setValue(SoPath * newValue)
109 Sets the first value in the array to newValue, and deletes the sec‐
110 ond and subsequent values.
111
112 int operator ==(const SoMFPath &f) const
113 int operator !=(const SoMFPath &f) const
114 Returns TRUE if all of the values of this field equal (do not equal)
115 those of the given field. If the fields are different types FALSE
116 will always be returned (even if one field is an SoMFFloat with one
117 value of 1.0 and the other is an SoMFInt with a value of 1, for
118 example).
119
120 SoPath * * startEditing()
121 void finishEditing()
122 startEditing() returns a pointer to the internally-maintained array
123 that can be modified. The values in the array may be changed, but
124 values cannot be added or removed. It is illegal to call any other
125 editing methods between startEditing() and finishEditing() (e.g.
126 set1Value(), setValue(), etc).
127
128 Fields, engines or sensors connected to this field and sensors are
129 not notified that this field has changed until finishEditing() is
130 called. Calling finishEditing() always sets the isDefault() flag to
131 FALSE and informs engines and sensors that the field changed, even
132 if none of the values actually were changed.
133
134
135
136
137 SoMFPath(3IV)()