HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HUSD_EditCollections.h
Go to the documentation of this file.
1 /*
2  * Copyright 2019 Side Effects Software Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17 
18 #ifndef __HUSD_EditCollections_h__
19 #define __HUSD_EditCollections_h__
20 
21 #include "HUSD_API.h"
22 #include "HUSD_DataHandle.h"
23 #include <UT/UT_StringHolder.h>
24 
25 class HUSD_FindPrims;
26 
28 {
29 public:
32 
33  bool createCollection(const UT_StringRef &primpath,
34  const UT_StringRef &collectionname,
35  const UT_StringRef &expansionrule,
36  const HUSD_FindPrims &includeprims,
37  const HUSD_FindPrims &excludeprims,
38  bool setexcludes,
39  bool createprim,
40  bool forceapply = true);
41 
42  bool createCollection(const UT_StringRef &primpath,
43  const UT_StringRef &collectionname,
44  const UT_StringRef &expansionrule,
45  const HUSD_FindPrims &includeprims,
46  bool createprim,
47  bool forceapply = true);
48 
49  bool createPathExpressionCollection(
50  const UT_StringRef &primpath,
51  const UT_StringRef &collectionname,
52  const UT_StringRef &pathexpression,
53  bool createprim,
54  bool forceapply = true);
55 
56  // Note, use HUSDmakeCollectionPath() to obtain collection path, if needed.
57  bool setCollectionExpansionRule(
58  const UT_StringRef &collectionpath,
59  const UT_StringRef &expansionrule);
60  bool setCollectionIncludes(
61  const UT_StringRef &collectionpath,
62  const UT_StringArray &paths);
63  bool addCollectionInclude(
64  const UT_StringRef &collectionpath,
65  const UT_StringRef &path);
66  bool setCollectionExcludes(
67  const UT_StringRef &collectionpath,
68  const UT_StringArray &paths);
69  bool addCollectionExclude(
70  const UT_StringRef &collectionpath,
71  const UT_StringRef &path);
72 
73  // Set an icon for use in our tree views.
74  bool setCollectionIcon(
75  const UT_StringRef &collectionpath,
76  const UT_StringHolder &icon);
77 
78 private:
79  bool createCollection(const UT_StringRef &primpath,
80  const UT_StringRef &collectionname,
81  const UT_StringRef &expansionrule,
82  const HUSD_FindPrims *includeprims,
83  const HUSD_FindPrims *excludeprims,
84  const UT_StringRef *pathexpression,
85  bool createprim,
86  bool forceapply);
87 
88  HUSD_AutoWriteLock &myWriteLock;
89 };
90 
91 #endif
92 
GLsizei const GLchar *const * path
Definition: glcorearb.h:3341
#define HUSD_API
Definition: HUSD_API.h:31