/usr/include/paraview/vtkSMIntVectorProperty.h is in paraview-dev 5.0.1+dfsg1-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 | /*=========================================================================
Program: ParaView
Module: vtkSMIntVectorProperty.h
Copyright (c) Kitware, Inc.
All rights reserved.
See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notice for more information.
=========================================================================*/
// .NAME vtkSMIntVectorProperty - property representing a vector of integers
// .SECTION Description
// vtkSMIntVectorProperty is a concrete sub-class of vtkSMVectorProperty
// representing a vector of integers.
// .SECTION See Also
// vtkSMVectorProperty vtkSMDoubleVectorProperty vtkSMStringVectorProperty
#ifndef vtkSMIntVectorProperty_h
#define vtkSMIntVectorProperty_h
#include "vtkPVServerManagerCoreModule.h" //needed for exports
#include "vtkSMVectorProperty.h"
class vtkSMStateLocator;
class VTKPVSERVERMANAGERCORE_EXPORT vtkSMIntVectorProperty : public vtkSMVectorProperty
{
public:
static vtkSMIntVectorProperty* New();
vtkTypeMacro(vtkSMIntVectorProperty, vtkSMVectorProperty);
void PrintSelf(ostream& os, vtkIndent indent);
// Description:
// Returns the size of the vector.
virtual unsigned int GetNumberOfElements();
// Description:
// Sets the size of the vector. If num is larger than the current
// number of elements, this may cause reallocation and copying.
virtual void SetNumberOfElements(unsigned int num);
// Description:
// Set the value of 1 element. The vector is resized as necessary.
// Returns 0 if Set fails either because the property is read only
// or the value is not in all domains. Returns 1 otherwise.
int SetElement(unsigned int idx, int value);
// Description:
// Set the values of all elements. The size of the values array
// has to be equal or larger to the size of the vector.
// Returns 0 if Set fails either because the property is read only
// or one or more of the values is not in all domains.
// Returns 1 otherwise.
int SetElements(const int* values);
int SetElements(const int* values, unsigned int numElems);
int *GetElements();
// Description:
// Sets the values of all the unchecked elements.
int SetUncheckedElements(const int* values);
int SetUncheckedElements(const int* values, unsigned int numValues);
// Description:
// Set the value of 1st element. The vector is resized as necessary.
// Returns 0 if Set fails either because the property is read only
// or one or more of the values is not in all domains.
// Returns 1 otherwise.
int SetElements1(int value0);
// Description:
// Set the values of the first 2 elements. The vector is resized as necessary.
// Returns 0 if Set fails either because the property is read only
// or one or more of the values is not in all domains.
// Returns 1 otherwise.
int SetElements2(int value0, int value1);
// Description:
// Set the values of the first 3 elements. The vector is resized as necessary.
// Returns 0 if Set fails either because the property is read only
// or one or more of the values is not in all domains.
// Returns 1 otherwise.
int SetElements3(int value0, int value1, int value2);
// Description:
// Returns the value of 1 element.
int GetElement(unsigned int idx);
// Description:
// Returns the value of 1 unchecked element. These are used by
// domains. SetElement() first sets the value of 1 unchecked
// element and then calls IsInDomain and updates the value of
// the corresponding element only if IsInDomain passes.
int GetUncheckedElement(unsigned int idx);
// Description:
// Set the value of 1 unchecked element. This can be used to
// check if a value is in all domains of the property. Call
// this and call IsInDomains().
void SetUncheckedElement(unsigned int idx, int value);
// Description:
// Returns the size of unchecked elements. Usually this is
// the same as the number of elements but can be different
// before a domain check is performed.
virtual unsigned int GetNumberOfUncheckedElements();
// Description:
// If ArgumentIsArray is true, multiple elements are passed in as
// array arguments. For example, For example, if
// RepeatCommand is true, NumberOfElementsPerCommand is 2, the
// command is SetFoo and the values are 1 2 3 4 5 6, the resulting
// stream will have:
// @verbatim
// * Invoke obj SetFoo array(1, 2)
// * Invoke obj SetFoo array(3, 4)
// * Invoke obj SetFoo array(5, 6)
// @endverbatim
vtkGetMacro(ArgumentIsArray, int);
vtkSetMacro(ArgumentIsArray, int);
vtkBooleanMacro(ArgumentIsArray, int);
// Description:
// Copy all property values.
virtual void Copy(vtkSMProperty* src);
// Description:
// Returns the default value, if any, specified in the XML.
int GetDefaultValue(int idx);
virtual void ClearUncheckedElements();
virtual bool IsValueDefault();
// Description:
// For properties that support specifying defaults in XML configuration, this
// method will reset the property value to the default values specified in the
// XML.
virtual void ResetToXMLDefaults();
//BTX
protected:
vtkSMIntVectorProperty();
~vtkSMIntVectorProperty();
// Description:
// Let the property write its content into the stream
virtual void WriteTo(vtkSMMessage*);
// Description:
// Let the property read and set its content from the stream
virtual void ReadFrom(const vtkSMMessage*, int msg_offset, vtkSMProxyLocator*);
// Handle XML with int type for default values.
virtual int ReadXMLAttributes(vtkSMProxy* parent, vtkPVXMLElement* element);
class vtkInternals;
vtkInternals* Internals;
int ArgumentIsArray;
// Description:
// Sets the size of unchecked elements. Usually this is
// the same as the number of elements but can be different
// before a domain check is performed.
virtual void SetNumberOfUncheckedElements(unsigned int num);
// Description:
// Load the XML state.
virtual int LoadState(vtkPVXMLElement* element, vtkSMProxyLocator* loader);
// Save concrete property values into the XML state property declaration
virtual void SaveStateValues(vtkPVXMLElement* propElement);
private:
vtkSMIntVectorProperty(const vtkSMIntVectorProperty&); // Not implemented
void operator=(const vtkSMIntVectorProperty&); // Not implemented
//ETX
};
#endif
|