libepp_nicbr
DefRegCreateCmd.H
Go to the documentation of this file.
1 /* ${copyright}$ */
2 /* $Id$ */
7 #ifndef __DEF_REG_CREATE_CMD_H__
8 #define __DEF_REG_CREATE_CMD_H__
9 
10 #include <string>
11 
12 #include "libepp_nicbr.H"
13 
14 #include "Command.H"
15 #include "CommonData.H"
16 #include "RegistrationPeriod.H"
17 
18 using std::string;
19 
20 LIBEPP_NICBR_NS_BEGIN
21 
23 class DefRegCreateCmd : public Command
24 {
25 public:
27  DefRegCreateCmd(bool reset = true) : Command(false)
28  {
29  if (reset) {
30  this->reset();
31  }
32  }
33 
35 
38  void set_name(const DefRegName &name) { _name = name; }
39 
41 
44  DefRegName get_name() const { return _name; }
45 
47 
50  void set_registrant(const string& registrant) { _registrant = registrant; }
51 
53 
56  string get_registrant() const { return _registrant; }
57 
60 
63  void set_trademark_id(const string &id) { _trademark_id = id; }
64 
67 
70  string get_trademark_id() const { return _trademark_id; }
71 
74 
77  void set_trademark_country(const string &country) { _trademark_country = country; }
78 
81 
84  string get_trademark_country() const { return _trademark_country; }
85 
87 
90  void set_trademark_date(const string &date) { _trademark_date = date; }
91 
93 
96  string get_trademark_date() const { return _trademark_date; }
97 
100 
104  void set_period(const int time, const string& unit)
105  {
106  _period.time = time;
107  _period.unit = unit;
108  }
109 
112 
116 
119 
122  void set_admin_contact(const string &contact) { _admin_contact = contact; }
123 
126 
129  string get_admin_contact() const { return _admin_contact; }
130 
132 
135  void set_authInfo(const AuthInfo &authInfo)
136  {
137  _authInfo = authInfo;
138  }
139 
141 
144  AuthInfo get_authInfo() const { return _authInfo; }
145 
147  void reset()
148  {
149  Command::reset();
150  _name.reset();
151  _registrant.clear();
152  _trademark_id.clear();
153  _trademark_country.clear();
154  _trademark_date.clear();
155  _period.time = 0;
156  _period.unit = "";
157  _admin_contact.clear();
158  _authInfo.reset();
159  }
160 
161 protected:
164 
168  string _registrant;
169 
173 
177 
180 
183 
187 
191 };
192 
193 LIBEPP_NICBR_NS_END
194 
195 #endif // __DEF_REG_CREATE_CMD_H__
EPP DefRegCreateCmd Class.
Definition: DefRegCreateCmd.H:23
Definition: RegistrationPeriod.H:17
string _trademark_country
Definition: DefRegCreateCmd.H:176
DefRegName _name
Name of the Defensive Registration object to be created.
Definition: DefRegCreateCmd.H:163
Project defines.
EPP CommonData Class.
EPP defensive registration Name Class.
Definition: CommonData.H:797
void set_trademark_country(const string &country)
Definition: DefRegCreateCmd.H:77
string get_trademark_date() const
Returns the date when the Trademark was issued.
Definition: DefRegCreateCmd.H:96
RegistrationPeriod _period
Initial registration period of the Defensive Registration object.
Definition: DefRegCreateCmd.H:182
string _trademark_date
Date when the Trademark was issued.
Definition: DefRegCreateCmd.H:179
string _registrant
Definition: DefRegCreateCmd.H:168
RegistrationPeriod get_period() const
Definition: DefRegCreateCmd.H:115
void set_registrant(const string &registrant)
Sets registrant.
Definition: DefRegCreateCmd.H:50
void set_trademark_id(const string &id)
Definition: DefRegCreateCmd.H:63
EPP RegistrationPeriod struct.
void set_name(const DefRegName &name)
Sets name of the Defensive Registration object.
Definition: DefRegCreateCmd.H:38
void set_trademark_date(const string &date)
Sets date when the Trademark was issued.
Definition: DefRegCreateCmd.H:90
AuthInfo get_authInfo() const
Returns authorization information.
Definition: DefRegCreateCmd.H:144
void reset()
Reset all object attributes.
Definition: CommonData.H:152
string get_admin_contact() const
Definition: DefRegCreateCmd.H:129
string get_trademark_country() const
Definition: DefRegCreateCmd.H:84
AuthInfo _authInfo
Definition: DefRegCreateCmd.H:190
string get_trademark_id() const
Definition: DefRegCreateCmd.H:70
void reset()
Reset object attributes.
Definition: Command.H:33
void set_period(const int time, const string &unit)
Definition: DefRegCreateCmd.H:104
EPP Command Class.
Definition: Command.H:18
void set_authInfo(const AuthInfo &authInfo)
Sets authorization information.
Definition: DefRegCreateCmd.H:135
void set_admin_contact(const string &contact)
Definition: DefRegCreateCmd.H:122
string _admin_contact
Definition: DefRegCreateCmd.H:186
DefRegName get_name() const
Returns name of the Defensive Registration object.
Definition: DefRegCreateCmd.H:44
void reset()
Resets object attributes.
Definition: CommonData.H:867
EPP Command Class.
string _trademark_id
Definition: DefRegCreateCmd.H:172
string get_registrant() const
Returns registrant.
Definition: DefRegCreateCmd.H:56
DefRegCreateCmd(bool reset=true)
Default constructor.
Definition: DefRegCreateCmd.H:27
AuthInfo Class.
Definition: CommonData.H:83
void reset()
Reset object attributes.
Definition: DefRegCreateCmd.H:147