HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HOM_StringParmTemplate.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * COMMENTS:
7  */
8 
9 #ifndef __HOM_StringParmTemplate_h__
10 #define __HOM_StringParmTemplate_h__
11 
12 #include "HOM_API.h"
13 #include "HOM_ParmTemplate.h"
14 
15 SWIGOUT(%feature("notabstract") HOM_StringParmTemplate;)
16 SWIGOUT(%rename(StringParmTemplate) HOM_StringParmTemplate;)
17 
19 {
20 public:
21 #ifdef SWIG
22 %extend {
23  %kwargs HOM_StringParmTemplate;
24  HOM_StringParmTemplate(
25  const char *name,
26  const char *label,
27  int num_components,
28  const std::vector<std::string> &default_value =
29  std::vector<std::string>(),
30  HOM_EnumValue &naming_scheme = HOM_parmNamingScheme::Base1,
31  HOM_EnumValue &string_type = HOM_stringParmType::Regular,
32  HOM_EnumValue &file_type = HOM_fileType::Any,
33  const std::vector<std::string> &menu_items =
34  std::vector<std::string>(),
35  const std::vector<std::string> &menu_labels =
36  std::vector<std::string>(),
37  const std::vector<std::string> &icon_names =
38  std::vector<std::string>(),
39  const std::string &item_generator_script = "",
40  HOM_EnumValue *item_generator_script_language = NULL,
41  HOM_EnumValue &menu_type = HOM_menuType::Normal,
42  const char *disable_when = NULL,
43  bool is_hidden = false,
44  bool is_label_hidden = false,
45  bool join_with_next = false,
46  const char *help = NULL,
47  const char *script_callback = NULL,
48  HOM_EnumValue &script_callback_language =
49  HOM_scriptLanguage::Hscript,
50  const std::map<std::string, std::string> &tags =
52  const std::map<HOM_EnumValue *, std::string> &conditionals =
54  const std::vector<std::string> &default_expression =
55  std::vector<std::string>(),
56  const std::vector<HOM_EnumValue *> &default_expression_language =
57  std::vector<HOM_EnumValue *>())
58  {
59  return HOM().newStringParmTemplate(
60  name, label, num_components, default_value,
61  naming_scheme, string_type, file_type, menu_items, menu_labels,
62  icon_names, item_generator_script, item_generator_script_language,
63  menu_type, disable_when, is_hidden, is_label_hidden, join_with_next,
64  help, script_callback, script_callback_language, tags, conditionals,
65  default_expression, default_expression_language);
66  }
67 };
68 #else
70  { HOM_CONSTRUCT_OBJECT(this) }
71 
73  : HOM_ParmTemplate(parm_template)
74  { HOM_CONSTRUCT_OBJECT(this) }
75 #endif
76 
78  { HOM_DESTRUCT_OBJECT(this) }
79 
80  // Let swig think we're overriding __repr__ for this class so it doesn't
81  // provide its own __repr__.
82  SWIGOUT(virtual std::string __repr__();)
83 
84  virtual HOM_EnumValue &stringType() = 0;
85  virtual void setStringType(HOM_EnumValue &string_type) = 0;
86 
87  virtual HOM_EnumValue &fileType() = 0;
88  virtual void setFileType(HOM_EnumValue &file_type) = 0;
89 
90  virtual std::vector<std::string> defaultValue() = 0;
91  virtual void setDefaultValue(
92  const std::vector<std::string> &default_value) = 0;
93  virtual std::vector<std::string> defaultExpression() = 0;
94  virtual void setDefaultExpression(
95  const std::vector<std::string> &default_expression) = 0;
96  virtual std::vector<HOM_EnumValue *> defaultExpressionLanguage() = 0;
97  virtual void setDefaultExpressionLanguage(
98  const std::vector<HOM_EnumValue *> &default_expression_language) = 0;
99 
100  virtual std::vector<std::string> menuItems() = 0;
101  virtual void setMenuItems(const std::vector<std::string> &menu_items) = 0;
102 
103  virtual std::vector<std::string> menuLabels() = 0;
104  virtual void setMenuLabels(const std::vector<std::string> &menu_labels) = 0;
105 
106  virtual std::vector<std::string> iconNames() = 0;
107  virtual void setIconNames(const std::vector<std::string> &icon_names) = 0;
108 
109  virtual std::string itemGeneratorScript() = 0;
110  virtual void setItemGeneratorScript(const char *item_generator_script) = 0;
111 
112  virtual HOM_EnumValue &itemGeneratorScriptLanguage() = 0;
113  virtual void setItemGeneratorScriptLanguage(HOM_EnumValue &language) = 0;
114 
115  virtual HOM_EnumValue &menuType() = 0;
116  virtual void setMenuType(HOM_EnumValue &menu_type) = 0;
117 };
118 
119 #endif
HOM_StringParmTemplate(const HOM_StringParmTemplate &parm_template)
#define HOM_DESTRUCT_OBJECT(pointer)
Definition: HOM_Module.h:1303
GLuint GLsizei const GLchar * label
Definition: glcorearb.h:2545
GLsizei const GLchar *const * string
Definition: glcorearb.h:814
#define SWIGOUT(x)
Definition: HOM_Defines.h:24
string __repr__(VtArray< T > const &self)
Definition: wrapArray.h:349
virtual HOM_StringParmTemplate * newStringParmTemplate(const char *name, const char *label, int num_components, const std::vector< std::string > &default_value, HOM_EnumValue &naming_scheme, HOM_EnumValue &string_type, HOM_EnumValue &file_type, const std::vector< std::string > &menu_items, const std::vector< std::string > &menu_labels, const std::vector< std::string > &icon_names, const std::string &item_generator_script, HOM_EnumValue *item_generator_script_language, HOM_EnumValue &menu_type, const char *disable_when, bool is_hidden, bool is_label_hidden, bool join_with_next, const char *help, const char *script_callback, HOM_EnumValue &script_callback_language, const std::map< std::string, std::string > &tags, const std::map< HOM_EnumValue *, std::string > &conditionals, const std::vector< std::string > &default_expression, const std::vector< HOM_EnumValue * > &default_expression_language)=0
std::string help(const App *app, const Error &e)
Printout the full help string on error (if this fn is set, the old default for CLI11) ...
Definition: CLI11.h:8978
#define HOM_API
Definition: HOM_API.h:13
#define HOM_CONSTRUCT_OBJECT(pointer)
Definition: HOM_Module.h:1302
GLuint const GLchar * name
Definition: glcorearb.h:786
std::map< HOM_EnumValue *, std::string > HOM_StdMapEnumString
Definition: HOM_Module.h:1312
OIIO_UTIL_API bool rename(string_view from, string_view to, std::string &err)
HOM_API HOM_Module & HOM()
std::map< std::string, std::string > HOM_StdMapStringString
Definition: HOM_Module.h:1311