├── .gitignore
├── README
├── example-request.xml
├── example-response.xml
├── main.go
└── test-client
├── ProjectService1.go
└── soap.go
/.gitignore:
--------------------------------------------------------------------------------
1 | *.exe
2 | test-client\*.exe
--------------------------------------------------------------------------------
/README:
--------------------------------------------------------------------------------
1 | Very early stage development of a general-purpose SOAP client for Go.
2 |
3 |
--------------------------------------------------------------------------------
/example-request.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/example-response.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | urn:replicon:list-type:string
12 | Project Name
13 | urn:replicon:project-list-column:name
14 |
15 |
16 | urn:replicon:list-type:string
17 | Code
18 | urn:replicon:project-list-column:code
19 |
20 |
21 | urn:replicon:list-type:object
22 | Status
23 | urn:replicon:project-list-column:status
24 |
25 |
26 | urn:replicon:list-type:object
27 | Client
28 | urn:replicon:project-list-column:client
29 |
30 |
31 | urn:replicon:list-type:object
32 | Program
33 | urn:replicon:project-list-column:program
34 |
35 |
36 | urn:replicon:list-type:object
37 | Billing Type
38 | urn:replicon:project-list-column:billing-type
39 |
40 |
41 | urn:replicon:list-type:object
42 | Department
43 | urn:replicon:project-list-column:department
44 |
45 |
46 | urn:replicon:list-type:object
47 | Project Leader
48 | urn:replicon:project-list-column:project-leader
49 |
50 |
51 | urn:replicon:list-type:date
52 | Start Date
53 | urn:replicon:project-list-column:start-date
54 |
55 |
56 | urn:replicon:list-type:date
57 | End Date
58 | urn:replicon:project-list-column:end-date
59 |
60 |
61 | Basic
62 | urn:replicon:project-list-column-group:basic
63 |
64 |
65 |
66 |
67 | urn:replicon:list-type:calendar-day-duration
68 | Total Estimated
69 | urn:replicon:project-list-column:total-estimated-hours
70 |
71 |
72 | urn:replicon:list-type:number
73 | FTE
74 | urn:replicon:project-list-column:hours-fte
75 |
76 |
77 | urn:replicon:list-type:calendar-day-duration
78 | Total Actual
79 | urn:replicon:project-list-column:total-actual-hours
80 |
81 |
82 | urn:replicon:list-type:calendar-day-duration
83 | Actual
84 | urn:replicon:project-list-column:actual-hours
85 |
86 |
87 | Hours
88 | urn:replicon:project-list-column-group:hours
89 |
90 |
91 |
92 |
93 | urn:replicon:list-type:money
94 | Total Estimated
95 | urn:replicon:project-list-column:total-estimated-cost
96 |
97 |
98 | urn:replicon:list-type:money
99 | Total Actual
100 | urn:replicon:project-list-column:total-actual-cost
101 |
102 |
103 | urn:replicon:list-type:money
104 | Actual
105 | urn:replicon:project-list-column:actual-cost
106 |
107 |
108 | Cost
109 | urn:replicon:project-list-column-group:cost
110 |
111 |
112 |
113 |
114 | urn:replicon:list-type:money
115 | Total Estimated
116 | urn:replicon:project-list-column:total-estimate-billing
117 |
118 |
119 | urn:replicon:list-type:money
120 | Total Actual
121 | urn:replicon:project-list-column:total-actual-billing
122 |
123 |
124 | urn:replicon:list-type:money
125 | Actual
126 | urn:replicon:project-list-column:actual-billing
127 |
128 |
129 | Billing
130 | urn:replicon:project-list-column-group:billing
131 |
132 |
133 |
134 |
135 | urn:replicon:list-type:money
136 | Allocated
137 | urn:replicon:project-list-column:budget-allocated
138 |
139 |
140 | Budget
141 | urn:replicon:project-list-column-group:budget
142 |
143 |
144 |
145 |
146 | urn:replicon:list-type:number
147 | Estimated
148 | urn:replicon:project-list-column:resources-estimated
149 |
150 |
151 | urn:replicon:list-type:number
152 | Already Assigned
153 | urn:replicon:project-list-column:resources-already-assigned
154 |
155 |
156 | urn:replicon:list-type:number
157 | Placeholder
158 | urn:replicon:project-list-column:resources-placeholders
159 |
160 |
161 | Resources
162 | urn:replicon:project-list-column-group:resources
163 |
164 |
165 |
166 |
167 |
168 |
--------------------------------------------------------------------------------
/main.go:
--------------------------------------------------------------------------------
1 | package main
2 |
3 | import (
4 | "bytes"
5 | "encoding/xml"
6 | "errors"
7 | "flag"
8 | "go/format"
9 | "io"
10 | "net/http"
11 | "net/url"
12 | "os"
13 | "sort"
14 | "strings"
15 | )
16 |
17 | type WsdlDefinitions struct {
18 | Name string `xml:"name,attr"`
19 | TargetNamespace string `xml:"targetNamespace,attr"`
20 | Imports []*WsdlImport `xml:"http://schemas.xmlsoap.org/wsdl/ import"`
21 | Types []*WsdlTypes `xml:"http://schemas.xmlsoap.org/wsdl/ types"`
22 | Messages []*WsdlMessage `xml:"http://schemas.xmlsoap.org/wsdl/ message"`
23 | PortTypes []*WsdlPortTypes `xml:"http://schemas.xmlsoap.org/wsdl/ portType"`
24 | Services []*WsdlService `xml:"http://schemas.xmlsoap.org/wsdl/ service"`
25 | Bindings []*WsdlBinding `xml:"http://schemas.xmlsoap.org/wsdl/ binding"`
26 | }
27 |
28 | type WsdlBinding struct {
29 | Name string `xml:"name,attr"`
30 | Type string `xml:"type,attr"`
31 | Operations []*WsdlOperation `xml:"http://schemas.xmlsoap.org/wsdl/ operation"`
32 | SoapBindings []*SoapBinding `xml:"http://schemas.xmlsoap.org/wsdl/soap/ binding"`
33 | }
34 |
35 | type SoapBinding struct {
36 | Transport string `xml:"transport,attr"`
37 | }
38 |
39 | type WsdlTypes struct {
40 | XsdSchema []*XsdSchema `xml:"http://www.w3.org/2001/XMLSchema schema"`
41 | }
42 |
43 | type WsdlImport struct {
44 | Namespace string `xml:"namespace,attr"`
45 | Location string `xml:"location,attr"`
46 | }
47 |
48 | type WsdlMessage struct {
49 | Name string `xml:"name,attr"`
50 | Parts []*WsdlMessagePart `xml:"http://schemas.xmlsoap.org/wsdl/ part"`
51 | }
52 |
53 | type WsdlMessagePart struct {
54 | Name string `xml:"name,attr"`
55 | Element string `xml:"element,attr"`
56 | }
57 |
58 | type WsdlPortTypes struct {
59 | Name string `xml:"name,attr"`
60 | Operations []*WsdlOperation `xml:"http://schemas.xmlsoap.org/wsdl/ operation"`
61 | }
62 |
63 | type WsdlOperation struct {
64 | Name string `xml:"name,attr"`
65 | Inputs []*WsdlOperationInput `xml:"http://schemas.xmlsoap.org/wsdl/ input"`
66 | Outputs []*WsdlOperationOutput `xml:"http://schemas.xmlsoap.org/wsdl/ output"`
67 | Faults []*WsdlOperationFault `xml:"http://schemas.xmlsoap.org/wsdl/ fault"`
68 | SoapOperations []*SoapOperation `xml:"http://schemas.xmlsoap.org/wsdl/soap/ operation"`
69 | }
70 |
71 | type WsdlOperationInput struct {
72 | Message string `xml:"message,attr"`
73 | WsawAction string `xml:"http://www.w3.org/2006/05/addressing/wsdl Action,attr"`
74 | }
75 |
76 | type WsdlOperationOutput struct {
77 | Message string `xml:"message,attr"`
78 | WsawAction string `xml:"http://www.w3.org/2006/05/addressing/wsdl Action,attr"`
79 | }
80 |
81 | type WsdlOperationFault struct {
82 | Name string `xml:"name,attr"`
83 | Message string `xml:"message,attr"`
84 | WsawAction string `xml:"http://www.w3.org/2006/05/addressing/wsdl Action,attr"`
85 | }
86 |
87 | type WsdlService struct {
88 | Name string `xml:"name,attr"`
89 | Ports []*WsdlPort `xml:"http://schemas.xmlsoap.org/wsdl/ port"`
90 | }
91 |
92 | type WsdlPort struct {
93 | Name string `xml:"name,attr"`
94 | Binding string `xml:"binding,attr"`
95 | SoapAddresses []*SoapAddress `xml:"http://schemas.xmlsoap.org/wsdl/soap/ address"`
96 | }
97 |
98 | type SoapAddress struct {
99 | Location string `xml:"location,attr"`
100 | }
101 |
102 | type SoapOperation struct {
103 | SoapAction string `xml:"soapAction,attr"`
104 | Style string `xml:"style,attr"`
105 | }
106 |
107 | type SoapBody struct {
108 | Use string `xml:"use,attr"`
109 | }
110 |
111 | type XsdSchema struct {
112 | TargetNamespace string `xml:"targetNamespace,attr"`
113 | ElementFormDefault string `xml:"elementFormDefault,attr"`
114 | Imports []*XsdImport `xml:"http://www.w3.org/2001/XMLSchema import"`
115 | Elements []*XsdElement `xml:"http://www.w3.org/2001/XMLSchema element"`
116 | ComplexTypes []*XsdComplexType `xml:"http://www.w3.org/2001/XMLSchema complexType"`
117 | }
118 |
119 | type XsdImport struct {
120 | SchemaLocation string `xml:"schemaLocation,attr"`
121 | Namespace string `xml:"namespace,attr"`
122 | }
123 |
124 | type XsdElement struct {
125 | Name string `xml:"name,attr"`
126 | Nillable bool `xml:"nillable,attr"`
127 | Type string `xml:"type,attr"`
128 | MinOccurs string `xml:"minOccurs,attr"`
129 | MaxOccurs string `xml:"maxOccurs,attr"`
130 | ComplexType *XsdComplexType `xml:"http://www.w3.org/2001/XMLSchema complexType"`
131 | SimpleType *XsdSimpleType `xml:"http://www.w3.org/2001/XMLSchema simpleType"`
132 | }
133 |
134 | type XsdComplexType struct {
135 | Name string `xml:"name,attr"`
136 | Sequence *XsdSequence `xml:"http://www.w3.org/2001/XMLSchema sequence"`
137 | }
138 |
139 | type XsdSimpleType struct {
140 | Name string `xml:"name,attr"`
141 | Sequence *XsdRestriction `xml:"http://www.w3.org/2001/XMLSchema restriction"`
142 | }
143 |
144 | type XsdSequence struct {
145 | Elements []*XsdElement `xml:"http://www.w3.org/2001/XMLSchema element"`
146 | }
147 |
148 | type XsdRestriction struct {
149 | Base string `xml:"base,attr"`
150 | Pattern *XsdPattern `xml:"http://www.w3.org/2001/XMLSchema pattern"`
151 | MinInclusive *XsdMinInclusive `xml:"http://www.w3.org/2001/XMLSchema minInclusive"`
152 | MaxInclusive *XsdMaxInclusive `xml:"http://www.w3.org/2001/XMLSchema maxInclusive"`
153 | }
154 |
155 | type XsdPattern struct {
156 | Value string `xml:"value,attr"`
157 | }
158 |
159 | type XsdMinInclusive struct {
160 | Value string `xml:"value,attr"`
161 | }
162 |
163 | type XsdMaxInclusive struct {
164 | Value string `xml:"value,attr"`
165 | }
166 |
167 | func main() {
168 | flag.Parse()
169 | wsdlRoot := flag.Arg(0)
170 |
171 | wsdlMap := make(map[string]*WsdlDefinitions)
172 | xsdMap := make(map[string]*XsdSchema)
173 |
174 | // "http://na2.replicon.com/services/ProjectService1.svc?wsdl"
175 | _, err := LoadWsdl(wsdlRoot, nil, wsdlMap, xsdMap)
176 | if err != nil {
177 | println("Error fetching WSDL:", err.Error())
178 | return
179 | }
180 |
181 | w := &bytes.Buffer{}
182 |
183 | //_, err = w.WriteString("package " + wsdl.Name)
184 | _, err = w.WriteString("package main\n\n")
185 | if err != nil {
186 | println("Error writing header:", err.Error())
187 | return
188 | }
189 | _, err = w.WriteString("import (\n")
190 | _, err = w.WriteString("\"encoding/xml\"\n")
191 | _, err = w.WriteString("\"math/big\"\n")
192 | _, err = w.WriteString(")\n")
193 | _, err = w.WriteString("var _ = big.MaxBase // Avoid potential unused-import error\n\n")
194 |
195 | complexTypes := make(NamedComplexTypeSlice, 0)
196 |
197 | for _, xsd := range xsdMap {
198 | for _, element := range xsd.Elements {
199 | if element.ComplexType == nil {
200 | continue
201 | }
202 | complexTypes = append(complexTypes, NamedComplexType{element.Name, element.ComplexType, xsd})
203 | }
204 | for _, complexType := range xsd.ComplexTypes {
205 | complexTypes = append(complexTypes, NamedComplexType{complexType.Name, complexType, xsd})
206 | }
207 | }
208 |
209 | sort.Sort(&complexTypes)
210 | for _, complexType := range complexTypes {
211 | WriteComplexType(w, complexType.Name, complexType.ComplexType, complexType.Xsd)
212 | }
213 |
214 | formattedOutput, err := format.Source(w.Bytes())
215 | if err != nil {
216 | println("Error while goformat'ing code:", err.Error())
217 | return
218 | }
219 |
220 | file, err := os.OpenFile("test-client/ProjectService1.go", os.O_CREATE|os.O_WRONLY|os.O_TRUNC, 0644)
221 | if err != nil {
222 | println("Error opening OutTest.wsdl:", err.Error())
223 | return
224 | }
225 | file.Write(formattedOutput)
226 | file.Close()
227 | }
228 |
229 | type NamedComplexType struct {
230 | Name string
231 | ComplexType *XsdComplexType
232 | Xsd *XsdSchema
233 | }
234 |
235 | type NamedComplexTypeSlice []NamedComplexType
236 |
237 | func (s *NamedComplexTypeSlice) Len() int {
238 | return len(*s)
239 | }
240 |
241 | func (s *NamedComplexTypeSlice) Less(i, j int) bool {
242 | return strings.ToLower((*s)[i].Name) < strings.ToLower((*s)[j].Name)
243 | }
244 |
245 | func (s *NamedComplexTypeSlice) Swap(i, j int) {
246 | (*s)[i], (*s)[j] = (*s)[j], (*s)[i]
247 | }
248 |
249 | func WriteComplexType(w io.Writer, elementName string, complexType *XsdComplexType, xsd *XsdSchema) {
250 | io.WriteString(w, "type ")
251 | io.WriteString(w, elementName)
252 | io.WriteString(w, " struct {\n")
253 |
254 | if complexType.Name == "" {
255 | io.WriteString(w, "\tXMLName xml.Name `xml:\"")
256 | io.WriteString(w, xsd.TargetNamespace)
257 | io.WriteString(w, " ")
258 | io.WriteString(w, elementName)
259 | io.WriteString(w, "\"`\n")
260 | }
261 |
262 | for _, element := range complexType.Sequence.Elements {
263 | io.WriteString(w, "\t")
264 | io.WriteString(w, strings.Title(element.Name))
265 | io.WriteString(w, " ")
266 | if element.MaxOccurs == "unbounded" {
267 | io.WriteString(w, "[]")
268 | }
269 | if element.MinOccurs == "0" {
270 | io.WriteString(w, "*")
271 | }
272 | io.WriteString(w, FindType(element.Type))
273 | io.WriteString(w, " `xml:\"")
274 | io.WriteString(w, xsd.TargetNamespace)
275 | io.WriteString(w, " ")
276 | io.WriteString(w, element.Name)
277 | io.WriteString(w, "\"`\n")
278 | }
279 | io.WriteString(w, "}\n\n")
280 | }
281 |
282 | func FindType(elementType string) string {
283 | if strings.HasPrefix(elementType, "tns:") {
284 | return elementType[4:]
285 | } else if elementType == "xs:boolean" {
286 | return "bool"
287 | } else if elementType == "xs:string" {
288 | return "string"
289 | } else if elementType == "xs:byte" {
290 | return "int8"
291 | } else if elementType == "xs:short" {
292 | return "int16"
293 | } else if elementType == "xs:int" {
294 | return "int32"
295 | } else if elementType == "xs:long" {
296 | return "int64"
297 | } else if elementType == "xs:unsignedByte" {
298 | return "uint8"
299 | } else if elementType == "xs:unsignedShort" {
300 | return "uint16"
301 | } else if elementType == "xs:unsignedInt" {
302 | return "uint32"
303 | } else if elementType == "xs:unsignedLong" {
304 | return "uint64"
305 | } else if elementType == "xs:integer" {
306 | return "big.Int"
307 | } else if elementType == "xs:nonPositiveInteger" {
308 | return "big.Int"
309 | } else if elementType == "xs:negativeInteger" {
310 | return "big.Int"
311 | } else if elementType == "xs:nonNegativeInteger" {
312 | return "big.Int"
313 | } else if elementType == "xs:positiveInteger" {
314 | return "big.Int"
315 | } else if elementType == "xs:decimal" {
316 | return "big.Rat"
317 | } else if elementType == "xs:float" {
318 | return "float32"
319 | } else if elementType == "xs:double" {
320 | return "float64"
321 | }
322 | /*
323 | xs:hexBinary
324 | xs:base64Binary
325 | xs:duration
326 | xs:dateTime
327 | xs:time
328 | xs:date
329 | xs:gYearMonth
330 | xs:gYear
331 | xs:gMonthDay
332 | xs:gDay
333 | xs:gMonth
334 | xs:anyURI
335 | xs:QName
336 | xs:NOTATION
337 | xs:normalizedString
338 | xs:token
339 | xs:language
340 | xs:ID
341 | xs:IDREF
342 | xs:IDREFS
343 | xs:ENTITY
344 | xs:ENTITIES
345 | xs:NMTOKEN
346 | xs:NMTOKENS
347 | xs:Name
348 | xs:NCName
349 | */
350 | return "string"
351 | }
352 |
353 | func GetAbsoluteUrl(rawUrl string, relativeRawUrl *string) (*url.URL, error) {
354 | targetUrl, err := url.Parse(rawUrl)
355 | if err != nil {
356 | return nil, err
357 | }
358 |
359 | if relativeRawUrl != nil {
360 | relativeUrl, err := url.Parse(*relativeRawUrl)
361 | if err != nil {
362 | return nil, err
363 | }
364 | targetUrl = relativeUrl.ResolveReference(targetUrl)
365 | }
366 |
367 | return targetUrl, nil
368 | }
369 |
370 | func LoadUrl(absoluteUrl url.URL) (io.Reader, error) {
371 | if absoluteUrl.Scheme == "http" || absoluteUrl.Scheme == "https" {
372 | response, err := http.Get(absoluteUrl.String())
373 | if err != nil {
374 | return nil, err
375 | }
376 | return response.Body, nil
377 | } else if absoluteUrl.Scheme == "file" {
378 | if absoluteUrl.Host != "" && absoluteUrl.Host != "localhost" {
379 | return nil, errors.New("file:// URL has unknown host " + absoluteUrl.Host)
380 | }
381 | path := absoluteUrl.String()[5:]
382 | return os.Open(path)
383 | }
384 | return nil, errors.New("unable to understand url scheme:" + absoluteUrl.Scheme)
385 | }
386 |
387 | func LoadWsdl(url string, relativeUrl *string, wsdlMap map[string]*WsdlDefinitions, xsdMap map[string]*XsdSchema) (retval *WsdlDefinitions, err error) {
388 | absoluteUrl, err := GetAbsoluteUrl(url, relativeUrl)
389 | if err != nil {
390 | return nil, err
391 | }
392 |
393 | existing := wsdlMap[absoluteUrl.String()]
394 | if existing != nil {
395 | return existing, nil
396 | }
397 |
398 | println("Loading WSDL:", absoluteUrl.String())
399 | response, err := LoadUrl(*absoluteUrl)
400 | if err != nil {
401 | return nil, err
402 | }
403 |
404 | retval, err = ParseWsdl(response, "http://dws-na2-int.replicon.com/", "http://na2.replicon.com/services/")
405 | if err != nil {
406 | return nil, err
407 | }
408 | wsdlMap[absoluteUrl.String()] = retval
409 |
410 | absoluteUrlString := absoluteUrl.String()
411 | for _, imp := range retval.Imports {
412 | wsdlMap[imp.Location], err = LoadWsdl(imp.Location, &absoluteUrlString, wsdlMap, xsdMap)
413 | if err != nil {
414 | return nil, err
415 | }
416 | }
417 |
418 | for _, types := range retval.Types {
419 | for _, schema := range types.XsdSchema {
420 | for _, imp := range schema.Imports {
421 | _, err = LoadXsd(imp.SchemaLocation, &absoluteUrlString, xsdMap)
422 | if err != nil {
423 | return nil, err
424 | }
425 | }
426 | }
427 | }
428 |
429 | return retval, nil
430 | }
431 |
432 | func LoadXsd(url string, relativeUrl *string, xsdMap map[string]*XsdSchema) (retval *XsdSchema, err error) {
433 | absoluteUrl, err := GetAbsoluteUrl(url, relativeUrl)
434 | if err != nil {
435 | return nil, err
436 | }
437 |
438 | existing := xsdMap[absoluteUrl.String()]
439 | if existing != nil {
440 | return existing, nil
441 | }
442 |
443 | println("Loading XSD:", absoluteUrl.String())
444 | response, err := LoadUrl(*absoluteUrl)
445 | if err != nil {
446 | return nil, err
447 | }
448 |
449 | retval, err = ParseXsd(response, "http://dws-na2-int.replicon.com/", "http://na2.replicon.com/services/")
450 | if err != nil {
451 | return nil, err
452 | }
453 | xsdMap[absoluteUrl.String()] = retval
454 |
455 | absoluteUrlString := absoluteUrl.String()
456 | for _, imp := range retval.Imports {
457 | _, err = LoadXsd(imp.SchemaLocation, &absoluteUrlString, xsdMap)
458 | }
459 |
460 | return retval, nil
461 | }
462 |
463 | func DebugPrintWsdl(wsdl *WsdlDefinitions) {
464 | println("WSDL:", wsdl.TargetNamespace, wsdl.Name)
465 | for _, imp := range wsdl.Imports {
466 | println("Import:", imp.Location, imp.Namespace)
467 | }
468 | for _, types := range wsdl.Types {
469 | for _, schema := range types.XsdSchema {
470 | println("Schema:", schema.TargetNamespace)
471 | for _, imp := range schema.Imports {
472 | println("\tImport:", imp.SchemaLocation, imp.Namespace)
473 | }
474 | }
475 | }
476 | for _, message := range wsdl.Messages {
477 | println("Message:", message.Name)
478 | for _, part := range message.Parts {
479 | println("\tPart:", part.Name, part.Element)
480 | }
481 | }
482 | for _, portType := range wsdl.PortTypes {
483 | println("PortType:", portType.Name)
484 | for _, operation := range portType.Operations {
485 | println("\tOperation:", operation.Name)
486 | for _, input := range operation.Inputs {
487 | println("\t\tInput:", input.Message, input.WsawAction)
488 | }
489 | for _, output := range operation.Outputs {
490 | println("\t\tOutput:", output.Message, output.WsawAction)
491 | }
492 | for _, fault := range operation.Faults {
493 | println("\t\tFault:", fault.Message, fault.WsawAction)
494 | }
495 | }
496 | }
497 | for _, service := range wsdl.Services {
498 | println("Service:", service.Name)
499 | for _, port := range service.Ports {
500 | println("\tPort:", port.Name, port.Binding)
501 | for _, address := range port.SoapAddresses {
502 | println("\t\tAddress:", address.Location)
503 | }
504 | }
505 | }
506 | for _, binding := range wsdl.Bindings {
507 | println("Binding:", binding.Name, binding.Type)
508 | for _, soapBinding := range binding.SoapBindings {
509 | println("\tSOAP Binding:", soapBinding.Transport)
510 | }
511 | for _, operation := range binding.Operations {
512 | println("\tOperation:", operation.Name)
513 | for _, soapOperation := range operation.SoapOperations {
514 | println("\t\tSOAP Operation:", soapOperation.SoapAction, soapOperation.Style)
515 | }
516 | }
517 | }
518 | }
519 |
520 | func ParseWsdl(reader io.Reader, urlSubstituteOld string, urlSubstituteNew string) (*WsdlDefinitions, error) {
521 | decoder := xml.NewDecoder(reader)
522 | obj := WsdlDefinitions{}
523 | err := decoder.Decode(&obj)
524 | if err != nil {
525 | return nil, err
526 | }
527 |
528 | for _, imp := range obj.Imports {
529 | imp.Location = strings.Replace(imp.Location, urlSubstituteOld, urlSubstituteNew, -1)
530 | }
531 | for _, types := range obj.Types {
532 | for _, schema := range types.XsdSchema {
533 | for _, imp := range schema.Imports {
534 | imp.SchemaLocation = strings.Replace(imp.SchemaLocation, urlSubstituteOld, urlSubstituteNew, -1)
535 | }
536 | }
537 | }
538 |
539 | return &obj, nil
540 | }
541 |
542 | func ParseXsd(reader io.Reader, urlSubstituteOld string, urlSubstituteNew string) (*XsdSchema, error) {
543 | decoder := xml.NewDecoder(reader)
544 | obj := XsdSchema{}
545 | err := decoder.Decode(&obj)
546 | if err != nil {
547 | return nil, err
548 | }
549 |
550 | for _, imp := range obj.Imports {
551 | imp.SchemaLocation = strings.Replace(imp.SchemaLocation, urlSubstituteOld, urlSubstituteNew, -1)
552 | }
553 |
554 | return &obj, nil
555 | }
556 |
557 | // println("WSDL:", obj.TargetNamespace, obj.Name)
558 | // for _, imp := range obj.Imports {
559 | // println("Import:", strings.Replace(imp.Namespace, substituteOld, substituteNew, -1), imp.Location)
560 | // }
561 | // for _, types := range obj.Types {
562 | // for _, schema := range types.XsdSchema {
563 | // println("Schema:", schema.TargetNamespace)
564 | // for _, imp := range schema.Imports {
565 | // println("\tImport:", strings.Replace(imp.SchemaLocation, substituteOld, substituteNew, -1), imp.Namespace)
566 | // }
567 | // }
568 | // }
569 | // for _, message := range obj.Messages {
570 | // println("Message:", message.Name)
571 | // for _, part := range message.Parts {
572 | // println("\tPart:", part.Name, part.Element)
573 | // }
574 | // }
575 | // for _, portType := range obj.PortTypes {
576 | // println("PortType:", portType.Name)
577 | // for _, operation := range portType.Operations {
578 | // println("\tOperation:", operation.Name)
579 | // for _, input := range operation.Inputs {
580 | // println("\t\tInput:", input.Message, input.WsawAction)
581 | // }
582 | // for _, output := range operation.Outputs {
583 | // println("\t\tOutput:", output.Message, output.WsawAction)
584 | // }
585 | // for _, fault := range operation.Faults {
586 | // println("\t\tFault:", fault.Message, fault.WsawAction)
587 | // }
588 | // }
589 | // }
590 | // for _, service := range obj.Services {
591 | // println("Service:", service.Name)
592 | // for _, port := range service.Ports {
593 | // println("\tPort:", port.Name, port.Binding)
594 | // for _, address := range port.SoapAddresses {
595 | // println("\t\tAddress:", address.Location)
596 | // }
597 | // }
598 | // }
599 | // for _, binding := range obj.Bindings {
600 | // println("Binding:", binding.Name, binding.Type)
601 | // for _, soapBinding := range binding.SoapBindings {
602 | // println("\tSOAP Binding:", soapBinding.Transport)
603 | // }
604 | // for _, operation := range binding.Operations {
605 | // println("\tOperation:", operation.Name)
606 | // for _, soapOperation := range operation.SoapOperations {
607 | // println("\t\tSOAP Operation:", soapOperation.SoapAction, soapOperation.Style)
608 | // }
609 | // }
610 | // }
611 |
612 | // /*
613 | // w, err := os.OpenFile("OutTest.wsdl", os.O_CREATE|os.O_WRONLY, 0644)
614 | // if err != nil {
615 | // println("Error opening OutTest.wsdl:", err.Error())
616 | // return
617 | // }
618 |
619 | // _, err = w.WriteString(xml.Header)
620 | // if err != nil {
621 | // println("Error writing header:", err.Error())
622 | // return
623 | // }
624 |
625 | // encoder := xml.NewEncoder(w)
626 | // err = encoder.Encode(&obj)
627 | // if err != nil {
628 | // println("Error encoding document:", err.Error())
629 | // return
630 | // }
631 |
632 | // w.Close()
633 | // */
634 | // }
635 |
--------------------------------------------------------------------------------
/test-client/ProjectService1.go:
--------------------------------------------------------------------------------
1 | package main
2 |
3 | import (
4 | "encoding/xml"
5 | "math/big"
6 | )
7 |
8 | var _ = big.MaxBase // Avoid potential unused-import error
9 |
10 | type ApplyNewClient struct {
11 | XMLName xml.Name `xml:"http://replicon.com/ ApplyNewClient"`
12 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
13 | ClientUri *string `xml:"http://replicon.com/ clientUri"`
14 | }
15 |
16 | type ApplyNewClientResponse struct {
17 | XMLName xml.Name `xml:"http://replicon.com/ ApplyNewClientResponse"`
18 | }
19 |
20 | type ApplyNewClientToProjectError1 struct {
21 | AreExpensesAlreadyEnteredAgainstProject *bool `xml:"http://replicon.com/ areExpensesAlreadyEnteredAgainstProject"`
22 | CurrentClient *ClientReference1 `xml:"http://replicon.com/ currentClient"`
23 | IsNewClientInactive *bool `xml:"http://replicon.com/ isNewClientInactive"`
24 | IsTimeAlreadyEnteredAgainstProject *bool `xml:"http://replicon.com/ isTimeAlreadyEnteredAgainstProject"`
25 | NewClient *ClientReference1 `xml:"http://replicon.com/ newClient"`
26 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
27 | }
28 |
29 | type ArrayOfanyURI struct {
30 | AnyURI []*string `xml:"http://schemas.microsoft.com/2003/10/Serialization/Arrays anyURI"`
31 | }
32 |
33 | type ArrayOfCustomFieldValueDetails1 struct {
34 | CustomFieldValueDetails1 []*CustomFieldValueDetails1 `xml:"http://replicon.com/ CustomFieldValueDetails1"`
35 | }
36 |
37 | type ArrayOfCustomFieldValueParameter1 struct {
38 | CustomFieldValueParameter1 []*CustomFieldValueParameter1 `xml:"http://replicon.com/ CustomFieldValueParameter1"`
39 | }
40 |
41 | type ArrayOfExpenseCodeChargeSummary1 struct {
42 | ExpenseCodeChargeSummary1 []*ExpenseCodeChargeSummary1 `xml:"http://replicon.com/ ExpenseCodeChargeSummary1"`
43 | }
44 |
45 | type ArrayOfExpenseCodeTargetParameter1 struct {
46 | ExpenseCodeTargetParameter1 []*ExpenseCodeTargetParameter1 `xml:"http://replicon.com/ ExpenseCodeTargetParameter1"`
47 | }
48 |
49 | type ArrayOfMoneyDetails1 struct {
50 | MoneyDetails1 []*MoneyDetails1 `xml:"http://replicon.com/ MoneyDetails1"`
51 | }
52 |
53 | type ArrayOfProjectBillableSeriesDataPoint1 struct {
54 | ProjectBillableSeriesDataPoint1 []*ProjectBillableSeriesDataPoint1 `xml:"http://replicon.com/ ProjectBillableSeriesDataPoint1"`
55 | }
56 |
57 | type ArrayOfProjectBillingRateDetails1 struct {
58 | ProjectBillingRateDetails1 []*ProjectBillingRateDetails1 `xml:"http://replicon.com/ ProjectBillingRateDetails1"`
59 | }
60 |
61 | type ArrayOfProjectCostSeriesDataPoint1 struct {
62 | ProjectCostSeriesDataPoint1 []*ProjectCostSeriesDataPoint1 `xml:"http://replicon.com/ ProjectCostSeriesDataPoint1"`
63 | }
64 |
65 | type ArrayOfProjectDeleteError1 struct {
66 | ProjectDeleteError1 []*ProjectDeleteError1 `xml:"http://replicon.com/ ProjectDeleteError1"`
67 | }
68 |
69 | type ArrayOfProjectDetails1 struct {
70 | ProjectDetails1 []*ProjectDetails1 `xml:"http://replicon.com/ ProjectDetails1"`
71 | }
72 |
73 | type ArrayOfProjectEstimationModeReference1 struct {
74 | ProjectEstimationModeReference1 []*ProjectEstimationModeReference1 `xml:"http://replicon.com/ ProjectEstimationModeReference1"`
75 | }
76 |
77 | type ArrayOfProjectExpenseCodeDetails1 struct {
78 | ProjectExpenseCodeDetails1 []*ProjectExpenseCodeDetails1 `xml:"http://replicon.com/ ProjectExpenseCodeDetails1"`
79 | }
80 |
81 | type ArrayOfProjectLeaderReference1 struct {
82 | ProjectLeaderReference1 []*ProjectLeaderReference1 `xml:"http://replicon.com/ ProjectLeaderReference1"`
83 | }
84 |
85 | type ArrayOfProjectReference1 struct {
86 | ProjectReference1 []*ProjectReference1 `xml:"http://replicon.com/ ProjectReference1"`
87 | }
88 |
89 | type ArrayOfProjectTeamMemberActualsSummary1 struct {
90 | ProjectTeamMemberActualsSummary1 []*ProjectTeamMemberActualsSummary1 `xml:"http://replicon.com/ ProjectTeamMemberActualsSummary1"`
91 | }
92 |
93 | type ArrayOfProjectTeamMemberAssignmentError1 struct {
94 | ProjectTeamMemberAssignmentError1 []*ProjectTeamMemberAssignmentError1 `xml:"http://replicon.com/ ProjectTeamMemberAssignmentError1"`
95 | }
96 |
97 | type ArrayOfProjectTeamMemberDetails1 struct {
98 | ProjectTeamMemberDetails1 []*ProjectTeamMemberDetails1 `xml:"http://replicon.com/ ProjectTeamMemberDetails1"`
99 | }
100 |
101 | type ArrayOfProjectTeamMemberParameter1 struct {
102 | ProjectTeamMemberParameter1 []*ProjectTeamMemberParameter1 `xml:"http://replicon.com/ ProjectTeamMemberParameter1"`
103 | }
104 |
105 | type ArrayOfProjectTeamMemberReference1 struct {
106 | ProjectTeamMemberReference1 []*ProjectTeamMemberReference1 `xml:"http://replicon.com/ ProjectTeamMemberReference1"`
107 | }
108 |
109 | type ArrayOfProjectTimeEnteredSeriesDataPoint1 struct {
110 | ProjectTimeEnteredSeriesDataPoint1 []*ProjectTimeEnteredSeriesDataPoint1 `xml:"http://replicon.com/ ProjectTimeEnteredSeriesDataPoint1"`
111 | }
112 |
113 | type ArrayOfResourceTargetParameter1 struct {
114 | ResourceTargetParameter1 []*ResourceTargetParameter1 `xml:"http://replicon.com/ ResourceTargetParameter1"`
115 | }
116 |
117 | type ArrayOfTaskHierarchyParameter1 struct {
118 | TaskHierarchyParameter1 []*TaskHierarchyParameter1 `xml:"http://replicon.com/ TaskHierarchyParameter1"`
119 | }
120 |
121 | type ArrayOfTaskHierarchyPutResults1 struct {
122 | TaskHierarchyPutResults1 []*TaskHierarchyPutResults1 `xml:"http://replicon.com/ TaskHierarchyPutResults1"`
123 | }
124 |
125 | type ArrayOfTaskReference1 struct {
126 | TaskReference1 []*TaskReference1 `xml:"http://replicon.com/ TaskReference1"`
127 | }
128 |
129 | type ArrayOfTaskResourceAssignmentDetails1 struct {
130 | TaskResourceAssignmentDetails1 []*TaskResourceAssignmentDetails1 `xml:"http://replicon.com/ TaskResourceAssignmentDetails1"`
131 | }
132 |
133 | type ArrayOfValidationNotificationSummary1 struct {
134 | ValidationNotificationSummary1 []*ValidationNotificationSummary1 `xml:"http://replicon.com/ ValidationNotificationSummary1"`
135 | }
136 |
137 | type AssignResourceToProject struct {
138 | XMLName xml.Name `xml:"http://replicon.com/ AssignResourceToProject"`
139 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
140 | ResourceUri *string `xml:"http://replicon.com/ resourceUri"`
141 | ResourceToReplaceUri *string `xml:"http://replicon.com/ resourceToReplaceUri"`
142 | }
143 |
144 | type AssignResourceToProjectError1 struct {
145 | DisplayText *string `xml:"http://replicon.com/ displayText"`
146 | FailureUri *string `xml:"http://replicon.com/ failureUri"`
147 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
148 | Resource *ResourceReference1 `xml:"http://replicon.com/ resource"`
149 | ResourceToReplace *ResourceReference1 `xml:"http://replicon.com/ resourceToReplace"`
150 | }
151 |
152 | type AssignResourceToProjectResponse struct {
153 | XMLName xml.Name `xml:"http://replicon.com/ AssignResourceToProjectResponse"`
154 | }
155 |
156 | type BillingRateAsOfDetails1 struct {
157 | AsOfDate *Date1 `xml:"http://replicon.com/ asOfDate"`
158 | BillingRateScheduleEntryUri *string `xml:"http://replicon.com/ billingRateScheduleEntryUri"`
159 | EffectiveDate *Date1 `xml:"http://replicon.com/ effectiveDate"`
160 | EndDate *Date1 `xml:"http://replicon.com/ endDate"`
161 | Value *MoneyDetails1 `xml:"http://replicon.com/ value"`
162 | }
163 |
164 | type BillingRateReference1 struct {
165 | DisplayText *string `xml:"http://replicon.com/ displayText"`
166 | Name *string `xml:"http://replicon.com/ name"`
167 | Uri *string `xml:"http://replicon.com/ uri"`
168 | }
169 |
170 | type BillingTypeReference1 struct {
171 | DisplayText *string `xml:"http://replicon.com/ displayText"`
172 | Uri *string `xml:"http://replicon.com/ uri"`
173 | }
174 |
175 | type BudgetDetails1 struct {
176 | Capital *MoneyDetails1 `xml:"http://replicon.com/ capital"`
177 | Operational *MoneyDetails1 `xml:"http://replicon.com/ operational"`
178 | Total *MoneyDetails1 `xml:"http://replicon.com/ total"`
179 | }
180 |
181 | type BudgetParameter1 struct {
182 | CapitalBudget *MoneyParameter1 `xml:"http://replicon.com/ capitalBudget"`
183 | OperationalBudget *MoneyParameter1 `xml:"http://replicon.com/ operationalBudget"`
184 | TotalBudget *MoneyParameter1 `xml:"http://replicon.com/ totalBudget"`
185 | }
186 |
187 | type BudgetParameter2 struct {
188 | CapitalBudget *MoneyParameter2 `xml:"http://replicon.com/ capitalBudget"`
189 | OperationalBudget *MoneyParameter2 `xml:"http://replicon.com/ operationalBudget"`
190 | TotalBudget *MoneyParameter2 `xml:"http://replicon.com/ totalBudget"`
191 | }
192 |
193 | type BulkDelete struct {
194 | XMLName xml.Name `xml:"http://replicon.com/ BulkDelete"`
195 | ProjectUris *string `xml:"http://replicon.com/ projectUris"`
196 | ProjectBulkDeleteOptionUri *string `xml:"http://replicon.com/ projectBulkDeleteOptionUri"`
197 | }
198 |
199 | type BulkDeleteResponse struct {
200 | XMLName xml.Name `xml:"http://replicon.com/ BulkDeleteResponse"`
201 | BulkDeleteResult *ProjectBulkDeleteResults1 `xml:"http://replicon.com/ BulkDeleteResult"`
202 | }
203 |
204 | type BulkGetProjectDetails struct {
205 | XMLName xml.Name `xml:"http://replicon.com/ BulkGetProjectDetails"`
206 | ProjectUris *string `xml:"http://replicon.com/ projectUris"`
207 | }
208 |
209 | type BulkGetProjectDetailsResponse struct {
210 | XMLName xml.Name `xml:"http://replicon.com/ BulkGetProjectDetailsResponse"`
211 | BulkGetProjectDetailsResult *ArrayOfProjectDetails1 `xml:"http://replicon.com/ BulkGetProjectDetailsResult"`
212 | }
213 |
214 | type BulkUpdateProjectTeamMembersAssignment struct {
215 | XMLName xml.Name `xml:"http://replicon.com/ BulkUpdateProjectTeamMembersAssignment"`
216 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
217 | ResourceUri *string `xml:"http://replicon.com/ resourceUri"`
218 | ProjectTeamMemberAssignmentOptionUri *string `xml:"http://replicon.com/ projectTeamMemberAssignmentOptionUri"`
219 | }
220 |
221 | type BulkUpdateProjectTeamMembersAssignmentResponse struct {
222 | XMLName xml.Name `xml:"http://replicon.com/ BulkUpdateProjectTeamMembersAssignmentResponse"`
223 | BulkUpdateProjectTeamMembersAssignmentResult *ProjectTeamMemberBulkUpdateAssignmentResults1 `xml:"http://replicon.com/ BulkUpdateProjectTeamMembersAssignmentResult"`
224 | }
225 |
226 | type CalendarDayDuration1 struct {
227 | Hours *int32 `xml:"http://replicon.com/ hours"`
228 | Minutes *int32 `xml:"http://replicon.com/ minutes"`
229 | Seconds *int32 `xml:"http://replicon.com/ seconds"`
230 | }
231 |
232 | type ChangeProjectToBeNonBillable struct {
233 | XMLName xml.Name `xml:"http://replicon.com/ ChangeProjectToBeNonBillable"`
234 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
235 | }
236 |
237 | type ChangeProjectToBeNonBillableResponse struct {
238 | XMLName xml.Name `xml:"http://replicon.com/ ChangeProjectToBeNonBillableResponse"`
239 | }
240 |
241 | type ClientReference1 struct {
242 | DisplayText *string `xml:"http://replicon.com/ displayText"`
243 | Name *string `xml:"http://replicon.com/ name"`
244 | Slug *string `xml:"http://replicon.com/ slug"`
245 | Uri *string `xml:"http://replicon.com/ uri"`
246 | }
247 |
248 | type ClientTargetParameter1 struct {
249 | Name *string `xml:"http://replicon.com/ name"`
250 | Uri *string `xml:"http://replicon.com/ uri"`
251 | }
252 |
253 | type CostTypeDetails1 struct {
254 | DisplayText *string `xml:"http://replicon.com/ displayText"`
255 | Uri *string `xml:"http://replicon.com/ uri"`
256 | }
257 |
258 | type CreateEditDraft struct {
259 | XMLName xml.Name `xml:"http://replicon.com/ CreateEditDraft"`
260 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
261 | }
262 |
263 | type CreateEditDraftResponse struct {
264 | XMLName xml.Name `xml:"http://replicon.com/ CreateEditDraftResponse"`
265 | CreateEditDraftResult *string `xml:"http://replicon.com/ CreateEditDraftResult"`
266 | }
267 |
268 | type CreateNewDraft struct {
269 | XMLName xml.Name `xml:"http://replicon.com/ CreateNewDraft"`
270 | }
271 |
272 | type CreateNewDraftResponse struct {
273 | XMLName xml.Name `xml:"http://replicon.com/ CreateNewDraftResponse"`
274 | CreateNewDraftResult *string `xml:"http://replicon.com/ CreateNewDraftResult"`
275 | }
276 |
277 | type CurrencyReference1 struct {
278 | DisplayText *string `xml:"http://replicon.com/ displayText"`
279 | Name *string `xml:"http://replicon.com/ name"`
280 | Symbol *string `xml:"http://replicon.com/ symbol"`
281 | Uri *string `xml:"http://replicon.com/ uri"`
282 | }
283 |
284 | type CurrencyTargetParameter1 struct {
285 | Name *string `xml:"http://replicon.com/ name"`
286 | Symbol *string `xml:"http://replicon.com/ symbol"`
287 | Uri *string `xml:"http://replicon.com/ uri"`
288 | }
289 |
290 | type CustomFieldDropDownOptionTargetParameter1 struct {
291 | Name *string `xml:"http://replicon.com/ name"`
292 | Uri *string `xml:"http://replicon.com/ uri"`
293 | }
294 |
295 | type CustomFieldReference1 struct {
296 | DisplayText *string `xml:"http://replicon.com/ displayText"`
297 | GroupUri *string `xml:"http://replicon.com/ groupUri"`
298 | Name *string `xml:"http://replicon.com/ name"`
299 | Uri *string `xml:"http://replicon.com/ uri"`
300 | }
301 |
302 | type CustomFieldTargetParameter1 struct {
303 | GroupUri *string `xml:"http://replicon.com/ groupUri"`
304 | Name *string `xml:"http://replicon.com/ name"`
305 | Uri *string `xml:"http://replicon.com/ uri"`
306 | }
307 |
308 | type CustomFieldTypeReference1 struct {
309 | DisplayText *string `xml:"http://replicon.com/ displayText"`
310 | Uri *string `xml:"http://replicon.com/ uri"`
311 | }
312 |
313 | type CustomFieldValueDetails1 struct {
314 | CustomField *CustomFieldReference1 `xml:"http://replicon.com/ customField"`
315 | CustomFieldType *CustomFieldTypeReference1 `xml:"http://replicon.com/ customFieldType"`
316 | Date *Date1 `xml:"http://replicon.com/ date"`
317 | DropDownOption *string `xml:"http://replicon.com/ dropDownOption"`
318 | Number *float64 `xml:"http://replicon.com/ number"`
319 | Text *string `xml:"http://replicon.com/ text"`
320 | }
321 |
322 | type CustomFieldValueParameter1 struct {
323 | CustomField CustomFieldTargetParameter1 `xml:"http://replicon.com/ customField"`
324 | Date *Date1 `xml:"http://replicon.com/ date"`
325 | DropDownOption *CustomFieldDropDownOptionTargetParameter1 `xml:"http://replicon.com/ dropDownOption"`
326 | Number *float64 `xml:"http://replicon.com/ number"`
327 | Text *string `xml:"http://replicon.com/ text"`
328 | }
329 |
330 | type Date1 struct {
331 | Day *int32 `xml:"http://replicon.com/ day"`
332 | Month *int32 `xml:"http://replicon.com/ month"`
333 | Year *int32 `xml:"http://replicon.com/ year"`
334 | }
335 |
336 | type DateRangeDetails1 struct {
337 | EndDate *Date1 `xml:"http://replicon.com/ endDate"`
338 | StartDate *Date1 `xml:"http://replicon.com/ startDate"`
339 | }
340 |
341 | type DateRangeParameter1 struct {
342 | EndDate *Date1 `xml:"http://replicon.com/ endDate"`
343 | RelativeDateRangeAsOfDate *Date1 `xml:"http://replicon.com/ relativeDateRangeAsOfDate"`
344 | RelativeDateRangeUri *string `xml:"http://replicon.com/ relativeDateRangeUri"`
345 | StartDate *Date1 `xml:"http://replicon.com/ startDate"`
346 | }
347 |
348 | type Delete struct {
349 | XMLName xml.Name `xml:"http://replicon.com/ Delete"`
350 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
351 | }
352 |
353 | type DeleteResponse struct {
354 | XMLName xml.Name `xml:"http://replicon.com/ DeleteResponse"`
355 | }
356 |
357 | type DepartmentReference1 struct {
358 | DisplayText *string `xml:"http://replicon.com/ displayText"`
359 | Name *string `xml:"http://replicon.com/ name"`
360 | Uri *string `xml:"http://replicon.com/ uri"`
361 | }
362 |
363 | type DepartmentTargetParameter1 struct {
364 | Name *string `xml:"http://replicon.com/ name"`
365 | ParameterCorrelationId *string `xml:"http://replicon.com/ parameterCorrelationId"`
366 | Parent *DepartmentTargetParameter1 `xml:"http://replicon.com/ parent"`
367 | Uri *string `xml:"http://replicon.com/ uri"`
368 | }
369 |
370 | type ExpenseCodeChargeSummary1 struct {
371 | ActualAmountCharged *MultiCurrencyMoneyDetails1 `xml:"http://replicon.com/ actualAmountCharged"`
372 | ExpenseCode *ExpenseCodeReference1 `xml:"http://replicon.com/ expenseCode"`
373 | }
374 |
375 | type ExpenseCodeReference1 struct {
376 | DisplayText *string `xml:"http://replicon.com/ displayText"`
377 | Name *string `xml:"http://replicon.com/ name"`
378 | Uri *string `xml:"http://replicon.com/ uri"`
379 | }
380 |
381 | type ExpenseCodeTargetParameter1 struct {
382 | Name *string `xml:"http://replicon.com/ name"`
383 | Uri *string `xml:"http://replicon.com/ uri"`
384 | }
385 |
386 | type GetAllProjectLeadersAssignedToProjects struct {
387 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjectLeadersAssignedToProjects"`
388 | }
389 |
390 | type GetAllProjectLeadersAssignedToProjectsResponse struct {
391 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjectLeadersAssignedToProjectsResponse"`
392 | GetAllProjectLeadersAssignedToProjectsResult *ArrayOfProjectLeaderReference1 `xml:"http://replicon.com/ GetAllProjectLeadersAssignedToProjectsResult"`
393 | }
394 |
395 | type GetAllProjects struct {
396 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjects"`
397 | }
398 |
399 | type GetAllProjectsResponse struct {
400 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjectsResponse"`
401 | GetAllProjectsResult *ArrayOfProjectReference1 `xml:"http://replicon.com/ GetAllProjectsResult"`
402 | }
403 |
404 | type GetAllProjectTeamMemberDetails struct {
405 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjectTeamMemberDetails"`
406 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
407 | AsOfDate *Date1 `xml:"http://replicon.com/ asOfDate"`
408 | }
409 |
410 | type GetAllProjectTeamMemberDetailsResponse struct {
411 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjectTeamMemberDetailsResponse"`
412 | GetAllProjectTeamMemberDetailsResult *ArrayOfProjectTeamMemberDetails1 `xml:"http://replicon.com/ GetAllProjectTeamMemberDetailsResult"`
413 | }
414 |
415 | type GetAllProjectTeamMembers struct {
416 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjectTeamMembers"`
417 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
418 | }
419 |
420 | type GetAllProjectTeamMembersResponse struct {
421 | XMLName xml.Name `xml:"http://replicon.com/ GetAllProjectTeamMembersResponse"`
422 | GetAllProjectTeamMembersResult *ArrayOfProjectTeamMemberReference1 `xml:"http://replicon.com/ GetAllProjectTeamMembersResult"`
423 | }
424 |
425 | type GetBillableAmountSeries struct {
426 | XMLName xml.Name `xml:"http://replicon.com/ GetBillableAmountSeries"`
427 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
428 | DateRange *DateRangeParameter1 `xml:"http://replicon.com/ dateRange"`
429 | PeriodResolutionUri *string `xml:"http://replicon.com/ periodResolutionUri"`
430 | }
431 |
432 | type GetBillableAmountSeriesResponse struct {
433 | XMLName xml.Name `xml:"http://replicon.com/ GetBillableAmountSeriesResponse"`
434 | GetBillableAmountSeriesResult *ProjectBillableSeries1 `xml:"http://replicon.com/ GetBillableAmountSeriesResult"`
435 | }
436 |
437 | type GetBillableAmountSummary struct {
438 | XMLName xml.Name `xml:"http://replicon.com/ GetBillableAmountSummary"`
439 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
440 | }
441 |
442 | type GetBillableAmountSummaryResponse struct {
443 | XMLName xml.Name `xml:"http://replicon.com/ GetBillableAmountSummaryResponse"`
444 | GetBillableAmountSummaryResult *ProjectBillableSummary1 `xml:"http://replicon.com/ GetBillableAmountSummaryResult"`
445 | }
446 |
447 | type GetChargesByExpenseCodeSummary struct {
448 | XMLName xml.Name `xml:"http://replicon.com/ GetChargesByExpenseCodeSummary"`
449 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
450 | }
451 |
452 | type GetChargesByExpenseCodeSummaryResponse struct {
453 | XMLName xml.Name `xml:"http://replicon.com/ GetChargesByExpenseCodeSummaryResponse"`
454 | GetChargesByExpenseCodeSummaryResult *ProjectChargesByExpenseCodeSummary1 `xml:"http://replicon.com/ GetChargesByExpenseCodeSummaryResult"`
455 | }
456 |
457 | type GetCostAmountSeries struct {
458 | XMLName xml.Name `xml:"http://replicon.com/ GetCostAmountSeries"`
459 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
460 | DateRange *DateRangeParameter1 `xml:"http://replicon.com/ dateRange"`
461 | PeriodResolutionUri *string `xml:"http://replicon.com/ periodResolutionUri"`
462 | }
463 |
464 | type GetCostAmountSeriesResponse struct {
465 | XMLName xml.Name `xml:"http://replicon.com/ GetCostAmountSeriesResponse"`
466 | GetCostAmountSeriesResult *ProjectCostSeries1 `xml:"http://replicon.com/ GetCostAmountSeriesResult"`
467 | }
468 |
469 | type GetCostAmountSummary struct {
470 | XMLName xml.Name `xml:"http://replicon.com/ GetCostAmountSummary"`
471 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
472 | }
473 |
474 | type GetCostAmountSummaryResponse struct {
475 | XMLName xml.Name `xml:"http://replicon.com/ GetCostAmountSummaryResponse"`
476 | GetCostAmountSummaryResult *ProjectCostSummary1 `xml:"http://replicon.com/ GetCostAmountSummaryResult"`
477 | }
478 |
479 | type GetEligibleEstimationModes struct {
480 | XMLName xml.Name `xml:"http://replicon.com/ GetEligibleEstimationModes"`
481 | }
482 |
483 | type GetEligibleEstimationModesResponse struct {
484 | XMLName xml.Name `xml:"http://replicon.com/ GetEligibleEstimationModesResponse"`
485 | GetEligibleEstimationModesResult *ArrayOfProjectEstimationModeReference1 `xml:"http://replicon.com/ GetEligibleEstimationModesResult"`
486 | }
487 |
488 | type GetEligibleProjectLeaders struct {
489 | XMLName xml.Name `xml:"http://replicon.com/ GetEligibleProjectLeaders"`
490 | }
491 |
492 | type GetEligibleProjectLeadersResponse struct {
493 | XMLName xml.Name `xml:"http://replicon.com/ GetEligibleProjectLeadersResponse"`
494 | GetEligibleProjectLeadersResult *ArrayOfProjectLeaderReference1 `xml:"http://replicon.com/ GetEligibleProjectLeadersResult"`
495 | }
496 |
497 | type GetExpenseCodes struct {
498 | XMLName xml.Name `xml:"http://replicon.com/ GetExpenseCodes"`
499 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
500 | }
501 |
502 | type GetExpenseCodesResponse struct {
503 | XMLName xml.Name `xml:"http://replicon.com/ GetExpenseCodesResponse"`
504 | GetExpenseCodesResult *ArrayOfProjectExpenseCodeDetails1 `xml:"http://replicon.com/ GetExpenseCodesResult"`
505 | }
506 |
507 | type GetExpenseCodesWhichCouldBeAllowingExpenseEntry struct {
508 | XMLName xml.Name `xml:"http://replicon.com/ GetExpenseCodesWhichCouldBeAllowingExpenseEntry"`
509 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
510 | }
511 |
512 | type GetExpenseCodesWhichCouldBeAllowingExpenseEntryResponse struct {
513 | XMLName xml.Name `xml:"http://replicon.com/ GetExpenseCodesWhichCouldBeAllowingExpenseEntryResponse"`
514 | GetExpenseCodesWhichCouldBeAllowingExpenseEntryResult *ArrayOfProjectExpenseCodeDetails1 `xml:"http://replicon.com/ GetExpenseCodesWhichCouldBeAllowingExpenseEntryResult"`
515 | }
516 |
517 | type GetProjectActualsByTeamMember struct {
518 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectActualsByTeamMember"`
519 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
520 | ProjectActualsByTeamMemberOptionUris *string `xml:"http://replicon.com/ projectActualsByTeamMemberOptionUris"`
521 | }
522 |
523 | type GetProjectActualsByTeamMemberResponse struct {
524 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectActualsByTeamMemberResponse"`
525 | GetProjectActualsByTeamMemberResult *ProjectActualsByTeamMemberSummary1 `xml:"http://replicon.com/ GetProjectActualsByTeamMemberResult"`
526 | }
527 |
528 | type GetProjectCodeSettingsForNewProjects struct {
529 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectCodeSettingsForNewProjects"`
530 | }
531 |
532 | type GetProjectCodeSettingsForNewProjectsResponse struct {
533 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectCodeSettingsForNewProjectsResponse"`
534 | GetProjectCodeSettingsForNewProjectsResult *ProjectCodeSettingsDetails1 `xml:"http://replicon.com/ GetProjectCodeSettingsForNewProjectsResult"`
535 | }
536 |
537 | type GetProjectDetails struct {
538 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectDetails"`
539 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
540 | }
541 |
542 | type GetProjectDetailsResponse struct {
543 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectDetailsResponse"`
544 | GetProjectDetailsResult *ProjectDetails1 `xml:"http://replicon.com/ GetProjectDetailsResult"`
545 | }
546 |
547 | type GetProjectNameFormatForNewUsers struct {
548 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectNameFormatForNewUsers"`
549 | }
550 |
551 | type GetProjectNameFormatForNewUsersResponse struct {
552 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectNameFormatForNewUsersResponse"`
553 | GetProjectNameFormatForNewUsersResult *string `xml:"http://replicon.com/ GetProjectNameFormatForNewUsersResult"`
554 | }
555 |
556 | type GetProjectNameFormatForUser struct {
557 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectNameFormatForUser"`
558 | UserUri *string `xml:"http://replicon.com/ userUri"`
559 | }
560 |
561 | type GetProjectNameFormatForUserResponse struct {
562 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectNameFormatForUserResponse"`
563 | GetProjectNameFormatForUserResult *string `xml:"http://replicon.com/ GetProjectNameFormatForUserResult"`
564 | }
565 |
566 | type GetProjectReferenceFromSlug struct {
567 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectReferenceFromSlug"`
568 | ProjectSlug *string `xml:"http://replicon.com/ projectSlug"`
569 | }
570 |
571 | type GetProjectReferenceFromSlugResponse struct {
572 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectReferenceFromSlugResponse"`
573 | GetProjectReferenceFromSlugResult *ProjectReference1 `xml:"http://replicon.com/ GetProjectReferenceFromSlugResult"`
574 | }
575 |
576 | type GetProjectTeamMemberDetails struct {
577 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectTeamMemberDetails"`
578 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
579 | ResourceUri *string `xml:"http://replicon.com/ resourceUri"`
580 | AsOfDate *Date1 `xml:"http://replicon.com/ asOfDate"`
581 | }
582 |
583 | type GetProjectTeamMemberDetailsResponse struct {
584 | XMLName xml.Name `xml:"http://replicon.com/ GetProjectTeamMemberDetailsResponse"`
585 | GetProjectTeamMemberDetailsResult *ProjectTeamMemberDetails1 `xml:"http://replicon.com/ GetProjectTeamMemberDetailsResult"`
586 | }
587 |
588 | type GetTaskAssignmentsForResource struct {
589 | XMLName xml.Name `xml:"http://replicon.com/ GetTaskAssignmentsForResource"`
590 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
591 | ResourceUri *string `xml:"http://replicon.com/ resourceUri"`
592 | AsOfDate *Date1 `xml:"http://replicon.com/ asOfDate"`
593 | }
594 |
595 | type GetTaskAssignmentsForResourceResponse struct {
596 | XMLName xml.Name `xml:"http://replicon.com/ GetTaskAssignmentsForResourceResponse"`
597 | GetTaskAssignmentsForResourceResult *ArrayOfTaskResourceAssignmentDetails1 `xml:"http://replicon.com/ GetTaskAssignmentsForResourceResult"`
598 | }
599 |
600 | type GetTimeEnteredSeries struct {
601 | XMLName xml.Name `xml:"http://replicon.com/ GetTimeEnteredSeries"`
602 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
603 | DateRange *DateRangeParameter1 `xml:"http://replicon.com/ dateRange"`
604 | PeriodResolutionUri *string `xml:"http://replicon.com/ periodResolutionUri"`
605 | }
606 |
607 | type GetTimeEnteredSeriesResponse struct {
608 | XMLName xml.Name `xml:"http://replicon.com/ GetTimeEnteredSeriesResponse"`
609 | GetTimeEnteredSeriesResult *ProjectTimeEnteredSeries1 `xml:"http://replicon.com/ GetTimeEnteredSeriesResult"`
610 | }
611 |
612 | type GetTimeEnteredSummary struct {
613 | XMLName xml.Name `xml:"http://replicon.com/ GetTimeEnteredSummary"`
614 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
615 | }
616 |
617 | type GetTimeEnteredSummaryResponse struct {
618 | XMLName xml.Name `xml:"http://replicon.com/ GetTimeEnteredSummaryResponse"`
619 | GetTimeEnteredSummaryResult *ProjectTimeEnteredSummary1 `xml:"http://replicon.com/ GetTimeEnteredSummaryResult"`
620 | }
621 |
622 | type GetUriFromSlug struct {
623 | XMLName xml.Name `xml:"http://replicon.com/ GetUriFromSlug"`
624 | ProjectSlug *string `xml:"http://replicon.com/ projectSlug"`
625 | }
626 |
627 | type GetUriFromSlugResponse struct {
628 | XMLName xml.Name `xml:"http://replicon.com/ GetUriFromSlugResponse"`
629 | GetUriFromSlugResult *string `xml:"http://replicon.com/ GetUriFromSlugResult"`
630 | }
631 |
632 | type InvalidBudgetParameterError1 struct {
633 | DisplayText *string `xml:"http://replicon.com/ displayText"`
634 | Parameter *BudgetParameter1 `xml:"http://replicon.com/ parameter"`
635 | }
636 |
637 | type InvalidDateRangeError1 struct {
638 | Context *DateRangeParameter1 `xml:"http://replicon.com/ context"`
639 | DisplayText *string `xml:"http://replicon.com/ displayText"`
640 | InvalidDateRangeErrorUri *string `xml:"http://replicon.com/ invalidDateRangeErrorUri"`
641 | }
642 |
643 | type InvalidProjectCompletionPercentageError1 struct {
644 | PercentCompleteEntered *int32 `xml:"http://replicon.com/ percentCompleteEntered"`
645 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
646 | }
647 |
648 | type InvalidProjectDetailsParameterError1 struct {
649 | DisplayText *string `xml:"http://replicon.com/ displayText"`
650 | Parameter *ProjectInfoParameter1 `xml:"http://replicon.com/ parameter"`
651 | }
652 |
653 | type InvalidProjectTargetParameterError1 struct {
654 | DisplayText *string `xml:"http://replicon.com/ displayText"`
655 | Target *ProjectTargetParameter1 `xml:"http://replicon.com/ target"`
656 | }
657 |
658 | type InvalidTaskTargetParameterError1 struct {
659 | DisplayText *string `xml:"http://replicon.com/ displayText"`
660 | Target *TaskTargetParameter1 `xml:"http://replicon.com/ target"`
661 | }
662 |
663 | type MoneyDetails1 struct {
664 | Amount *big.Rat `xml:"http://replicon.com/ amount"`
665 | Currency *CurrencyReference1 `xml:"http://replicon.com/ currency"`
666 | }
667 |
668 | type MoneyParameter1 struct {
669 | Amount big.Rat `xml:"http://replicon.com/ amount"`
670 | CurrencyUri string `xml:"http://replicon.com/ currencyUri"`
671 | }
672 |
673 | type MoneyParameter2 struct {
674 | Amount big.Rat `xml:"http://replicon.com/ amount"`
675 | Currency CurrencyTargetParameter1 `xml:"http://replicon.com/ currency"`
676 | }
677 |
678 | type MultiCurrencyMoneyDetails1 struct {
679 | BaseCurrencyValue *MoneyDetails1 `xml:"http://replicon.com/ baseCurrencyValue"`
680 | BaseCurrencyValueAsOfDate *Date1 `xml:"http://replicon.com/ baseCurrencyValueAsOfDate"`
681 | MultiCurrencyValue *ArrayOfMoneyDetails1 `xml:"http://replicon.com/ multiCurrencyValue"`
682 | }
683 |
684 | type PeriodDetails1 struct {
685 | Day *int32 `xml:"http://replicon.com/ day"`
686 | Month *int32 `xml:"http://replicon.com/ month"`
687 | PeriodEnd *Date1 `xml:"http://replicon.com/ periodEnd"`
688 | PeriodStart *Date1 `xml:"http://replicon.com/ periodStart"`
689 | Quarter *int32 `xml:"http://replicon.com/ quarter"`
690 | Week *int32 `xml:"http://replicon.com/ week"`
691 | Year *int32 `xml:"http://replicon.com/ year"`
692 | }
693 |
694 | type ProgramReference1 struct {
695 | DisplayText *string `xml:"http://replicon.com/ displayText"`
696 | Name *string `xml:"http://replicon.com/ name"`
697 | Slug *string `xml:"http://replicon.com/ slug"`
698 | Uri *string `xml:"http://replicon.com/ uri"`
699 | }
700 |
701 | type ProgramTargetParameter1 struct {
702 | Name *string `xml:"http://replicon.com/ name"`
703 | Uri *string `xml:"http://replicon.com/ uri"`
704 | }
705 |
706 | type ProjectActualsByTeamMemberSummary1 struct {
707 | ActualBillingTotal *MultiCurrencyMoneyDetails1 `xml:"http://replicon.com/ actualBillingTotal"`
708 | ActualCostTotal *MultiCurrencyMoneyDetails1 `xml:"http://replicon.com/ actualCostTotal"`
709 | ActualHoursTotal *CalendarDayDuration1 `xml:"http://replicon.com/ actualHoursTotal"`
710 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
711 | TeamMemberSummaries *ArrayOfProjectTeamMemberActualsSummary1 `xml:"http://replicon.com/ teamMemberSummaries"`
712 | }
713 |
714 | type ProjectBillableSeries1 struct {
715 | Currency *CurrencyReference1 `xml:"http://replicon.com/ currency"`
716 | DataPoints *ArrayOfProjectBillableSeriesDataPoint1 `xml:"http://replicon.com/ dataPoints"`
717 | }
718 |
719 | type ProjectBillableSeriesDataPoint1 struct {
720 | BillableAmountActual *big.Rat `xml:"http://replicon.com/ billableAmountActual"`
721 | BillableAmountDelta *big.Rat `xml:"http://replicon.com/ billableAmountDelta"`
722 | BillableAmountEstimated *big.Rat `xml:"http://replicon.com/ billableAmountEstimated"`
723 | Period *PeriodDetails1 `xml:"http://replicon.com/ period"`
724 | }
725 |
726 | type ProjectBillableSummary1 struct {
727 | BillableActual *MoneyDetails1 `xml:"http://replicon.com/ billableActual"`
728 | BillableEstimatedToDate *MoneyDetails1 `xml:"http://replicon.com/ billableEstimatedToDate"`
729 | BillableTotalEstimated *MoneyDetails1 `xml:"http://replicon.com/ billableTotalEstimated"`
730 | PaidTotal *MoneyDetails1 `xml:"http://replicon.com/ paidTotal"`
731 | PendingTotal *MoneyDetails1 `xml:"http://replicon.com/ pendingTotal"`
732 | }
733 |
734 | type ProjectBillingRateDetails1 struct {
735 | BillingRate *BillingRateReference1 `xml:"http://replicon.com/ billingRate"`
736 | EffectiveBillingRate *BillingRateAsOfDetails1 `xml:"http://replicon.com/ effectiveBillingRate"`
737 | IsAvailableForAssignmentToTeamMembers *bool `xml:"http://replicon.com/ isAvailableForAssignmentToTeamMembers"`
738 | }
739 |
740 | type ProjectBulkDeleteResults1 struct {
741 | ArchivedUris *string `xml:"http://replicon.com/ archivedUris"`
742 | DeletedUris *string `xml:"http://replicon.com/ deletedUris"`
743 | Errors *ArrayOfProjectDeleteError1 `xml:"http://replicon.com/ errors"`
744 | }
745 |
746 | type ProjectChargesByExpenseCodeSummary1 struct {
747 | ExpenseCodeSummaries *ArrayOfExpenseCodeChargeSummary1 `xml:"http://replicon.com/ expenseCodeSummaries"`
748 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
749 | TotalActualAmountCharged *MultiCurrencyMoneyDetails1 `xml:"http://replicon.com/ totalActualAmountCharged"`
750 | }
751 |
752 | type ProjectCodeSettingsDetails1 struct {
753 | NextProjectCode *uint32 `xml:"http://replicon.com/ nextProjectCode"`
754 | ProjectCodeSettingOption *string `xml:"http://replicon.com/ projectCodeSettingOption"`
755 | }
756 |
757 | type ProjectCostSeries1 struct {
758 | Currency *CurrencyReference1 `xml:"http://replicon.com/ currency"`
759 | DataPoints *ArrayOfProjectCostSeriesDataPoint1 `xml:"http://replicon.com/ dataPoints"`
760 | }
761 |
762 | type ProjectCostSeriesDataPoint1 struct {
763 | CostAmountActual *big.Rat `xml:"http://replicon.com/ costAmountActual"`
764 | CostAmountDelta *big.Rat `xml:"http://replicon.com/ costAmountDelta"`
765 | CostAmountEstimated *big.Rat `xml:"http://replicon.com/ costAmountEstimated"`
766 | Period *PeriodDetails1 `xml:"http://replicon.com/ period"`
767 | }
768 |
769 | type ProjectCostSummary1 struct {
770 | CostActual *MoneyDetails1 `xml:"http://replicon.com/ costActual"`
771 | CostEstimatedToDate *MoneyDetails1 `xml:"http://replicon.com/ costEstimatedToDate"`
772 | CostTotalEstimated *MoneyDetails1 `xml:"http://replicon.com/ costTotalEstimated"`
773 | }
774 |
775 | type ProjectDeleteError1 struct {
776 | DisplayText *string `xml:"http://replicon.com/ displayText"`
777 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
778 | }
779 |
780 | type ProjectDetails1 struct {
781 | BillingType *BillingTypeReference1 `xml:"http://replicon.com/ billingType"`
782 | Budget *BudgetDetails1 `xml:"http://replicon.com/ budget"`
783 | Client *ClientReference1 `xml:"http://replicon.com/ client"`
784 | Code *string `xml:"http://replicon.com/ code"`
785 | CostType *CostTypeDetails1 `xml:"http://replicon.com/ costType"`
786 | CustomFields *ArrayOfCustomFieldValueDetails1 `xml:"http://replicon.com/ customFields"`
787 | Description *string `xml:"http://replicon.com/ description"`
788 | DisplayText *string `xml:"http://replicon.com/ displayText"`
789 | EstimatedCost *MoneyDetails1 `xml:"http://replicon.com/ estimatedCost"`
790 | EstimatedExpenses *MoneyDetails1 `xml:"http://replicon.com/ estimatedExpenses"`
791 | EstimatedHours *TaskDuration1 `xml:"http://replicon.com/ estimatedHours"`
792 | EstimationMode *ProjectEstimationModeReference1 `xml:"http://replicon.com/ estimationMode"`
793 | IsProjectLeaderApprovalRequired *bool `xml:"http://replicon.com/ isProjectLeaderApprovalRequired"`
794 | IsTimeEntryAllowed *bool `xml:"http://replicon.com/ isTimeEntryAllowed"`
795 | Name *string `xml:"http://replicon.com/ name"`
796 | PercentCompleted *int32 `xml:"http://replicon.com/ percentCompleted"`
797 | Program *ProgramReference1 `xml:"http://replicon.com/ program"`
798 | ProjectLeader *ProjectLeaderReference1 `xml:"http://replicon.com/ projectLeader"`
799 | Slug *string `xml:"http://replicon.com/ slug"`
800 | Status *ProjectStatusLabelReference1 `xml:"http://replicon.com/ status"`
801 | TimeAndExpenseEntryType *TimeAndExpenseEntryTypeReference1 `xml:"http://replicon.com/ timeAndExpenseEntryType"`
802 | TimeEntryDateRange *DateRangeDetails1 `xml:"http://replicon.com/ timeEntryDateRange"`
803 | Uri *string `xml:"http://replicon.com/ uri"`
804 | }
805 |
806 | type ProjectEstimationModeReference1 struct {
807 | DisplayText *string `xml:"http://replicon.com/ displayText"`
808 | Uri *string `xml:"http://replicon.com/ uri"`
809 | }
810 |
811 | type ProjectExpenseCodeDetails1 struct {
812 | ExpenseCode *ExpenseCodeReference1 `xml:"http://replicon.com/ expenseCode"`
813 | IsExpenseEntryToThisCodeAllowed *bool `xml:"http://replicon.com/ isExpenseEntryToThisCodeAllowed"`
814 | }
815 |
816 | type ProjectExpensesParameter1 struct {
817 | ExpenseCodes *ArrayOfExpenseCodeTargetParameter1 `xml:"http://replicon.com/ expenseCodes"`
818 | }
819 |
820 | type ProjectInfoParameter1 struct {
821 | Budget *BudgetParameter2 `xml:"http://replicon.com/ budget"`
822 | Client *ClientTargetParameter1 `xml:"http://replicon.com/ client"`
823 | Code *string `xml:"http://replicon.com/ code"`
824 | CostTypeUri *string `xml:"http://replicon.com/ costTypeUri"`
825 | CustomFieldValues *ArrayOfCustomFieldValueParameter1 `xml:"http://replicon.com/ customFieldValues"`
826 | Description *string `xml:"http://replicon.com/ description"`
827 | EstimatedCost *MoneyParameter2 `xml:"http://replicon.com/ estimatedCost"`
828 | EstimatedExpenses *MoneyParameter2 `xml:"http://replicon.com/ estimatedExpenses"`
829 | EstimatedHours *TaskDuration1 `xml:"http://replicon.com/ estimatedHours"`
830 | EstimationModeUri *string `xml:"http://replicon.com/ estimationModeUri"`
831 | IsProjectLeaderApprovalRequired *bool `xml:"http://replicon.com/ isProjectLeaderApprovalRequired"`
832 | IsTimeEntryAllowed *bool `xml:"http://replicon.com/ isTimeEntryAllowed"`
833 | Name *string `xml:"http://replicon.com/ name"`
834 | PercentCompleted *int32 `xml:"http://replicon.com/ percentCompleted"`
835 | Program *ProgramTargetParameter1 `xml:"http://replicon.com/ program"`
836 | ProjectLeader *UserTargetParameter1 `xml:"http://replicon.com/ projectLeader"`
837 | ProjectStatusLabel *ProjectStatusLabelTargetParameter1 `xml:"http://replicon.com/ projectStatusLabel"`
838 | TimeEntryDateRange *DateRangeParameter1 `xml:"http://replicon.com/ timeEntryDateRange"`
839 | }
840 |
841 | type ProjectLeaderReference1 struct {
842 | DisplayText *string `xml:"http://replicon.com/ displayText"`
843 | Uri *string `xml:"http://replicon.com/ uri"`
844 | User *UserReference1 `xml:"http://replicon.com/ user"`
845 | }
846 |
847 | type ProjectParameter1 struct {
848 | Expenses *ProjectExpensesParameter1 `xml:"http://replicon.com/ expenses"`
849 | ProjectInfo *ProjectInfoParameter1 `xml:"http://replicon.com/ projectInfo"`
850 | Target *ProjectTargetParameter1 `xml:"http://replicon.com/ target"`
851 | Tasks *ArrayOfTaskHierarchyParameter1 `xml:"http://replicon.com/ tasks"`
852 | Team *ProjectTeamParameter1 `xml:"http://replicon.com/ team"`
853 | }
854 |
855 | type ProjectReference1 struct {
856 | DisplayText *string `xml:"http://replicon.com/ displayText"`
857 | Name *string `xml:"http://replicon.com/ name"`
858 | Slug *string `xml:"http://replicon.com/ slug"`
859 | Uri *string `xml:"http://replicon.com/ uri"`
860 | }
861 |
862 | type ProjectRoleReference1 struct {
863 | DisplayText *string `xml:"http://replicon.com/ displayText"`
864 | Name *string `xml:"http://replicon.com/ name"`
865 | Uri *string `xml:"http://replicon.com/ uri"`
866 | }
867 |
868 | type ProjectRoleTargetParameter1 struct {
869 | Name *string `xml:"http://replicon.com/ name"`
870 | Uri *string `xml:"http://replicon.com/ uri"`
871 | }
872 |
873 | type ProjectStatusLabelReference1 struct {
874 | DisplayText *string `xml:"http://replicon.com/ displayText"`
875 | Name *string `xml:"http://replicon.com/ name"`
876 | Uri *string `xml:"http://replicon.com/ uri"`
877 | }
878 |
879 | type ProjectStatusLabelTargetParameter1 struct {
880 | Name *string `xml:"http://replicon.com/ name"`
881 | Uri *string `xml:"http://replicon.com/ uri"`
882 | }
883 |
884 | type ProjectTargetParameter1 struct {
885 | Name *string `xml:"http://replicon.com/ name"`
886 | Uri *string `xml:"http://replicon.com/ uri"`
887 | }
888 |
889 | type ProjectTeamMemberActualsSummary1 struct {
890 | ActualBillingTotal *MultiCurrencyMoneyDetails1 `xml:"http://replicon.com/ actualBillingTotal"`
891 | ActualCostTotal *MultiCurrencyMoneyDetails1 `xml:"http://replicon.com/ actualCostTotal"`
892 | ActualHoursTotal *CalendarDayDuration1 `xml:"http://replicon.com/ actualHoursTotal"`
893 | IsActiveProjectTeamMember *bool `xml:"http://replicon.com/ isActiveProjectTeamMember"`
894 | Resource *ResourceReference1 `xml:"http://replicon.com/ resource"`
895 | }
896 |
897 | type ProjectTeamMemberAssignmentError1 struct {
898 | AssignedTasks *ArrayOfTaskReference1 `xml:"http://replicon.com/ assignedTasks"`
899 | ProjectTeamMember *ProjectTeamMemberReference1 `xml:"http://replicon.com/ projectTeamMember"`
900 | }
901 |
902 | type ProjectTeamMemberBulkUpdateAssignmentResults1 struct {
903 | Errors *ArrayOfProjectTeamMemberAssignmentError1 `xml:"http://replicon.com/ errors"`
904 | Updated *string `xml:"http://replicon.com/ updated"`
905 | }
906 |
907 | type ProjectTeamMemberDetails1 struct {
908 | BillingRatesAllowedForBillingTime *ArrayOfProjectBillingRateDetails1 `xml:"http://replicon.com/ billingRatesAllowedForBillingTime"`
909 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
910 | Resource *ResourceReference1 `xml:"http://replicon.com/ resource"`
911 | Role *ProjectRoleReference1 `xml:"http://replicon.com/ role"`
912 | }
913 |
914 | type ProjectTeamMemberParameter1 struct {
915 | Resource *ResourceTargetParameter1 `xml:"http://replicon.com/ resource"`
916 | ResourcePlaceholderProjectRole *ProjectRoleTargetParameter1 `xml:"http://replicon.com/ resourcePlaceholderProjectRole"`
917 | }
918 |
919 | type ProjectTeamMemberReference1 struct {
920 | Project *ProjectReference1 `xml:"http://replicon.com/ project"`
921 | Resource *ResourceReference1 `xml:"http://replicon.com/ resource"`
922 | }
923 |
924 | type ProjectTeamParameter1 struct {
925 | TeamMembers *ArrayOfProjectTeamMemberParameter1 `xml:"http://replicon.com/ teamMembers"`
926 | }
927 |
928 | type ProjectTimeEnteredSeries1 struct {
929 | DataPoints *ArrayOfProjectTimeEnteredSeriesDataPoint1 `xml:"http://replicon.com/ dataPoints"`
930 | }
931 |
932 | type ProjectTimeEnteredSeriesDataPoint1 struct {
933 | Period *PeriodDetails1 `xml:"http://replicon.com/ period"`
934 | TimeEnteredActual *CalendarDayDuration1 `xml:"http://replicon.com/ timeEnteredActual"`
935 | TimeEnteredDelta *CalendarDayDuration1 `xml:"http://replicon.com/ timeEnteredDelta"`
936 | TimeEnteredEstimated *CalendarDayDuration1 `xml:"http://replicon.com/ timeEnteredEstimated"`
937 | }
938 |
939 | type ProjectTimeEnteredSummary1 struct {
940 | TimeEnteredActual *CalendarDayDuration1 `xml:"http://replicon.com/ timeEnteredActual"`
941 | TimeEnteredEstimatedToDate *CalendarDayDuration1 `xml:"http://replicon.com/ timeEnteredEstimatedToDate"`
942 | TimeEnteredTotalEstimated *CalendarDayDuration1 `xml:"http://replicon.com/ timeEnteredTotalEstimated"`
943 | }
944 |
945 | type PublishDraft struct {
946 | XMLName xml.Name `xml:"http://replicon.com/ PublishDraft"`
947 | DraftUri *string `xml:"http://replicon.com/ draftUri"`
948 | }
949 |
950 | type PublishDraftResponse struct {
951 | XMLName xml.Name `xml:"http://replicon.com/ PublishDraftResponse"`
952 | PublishDraftResult *ProjectReference1 `xml:"http://replicon.com/ PublishDraftResult"`
953 | }
954 |
955 | type PutExpenseCodesAllowingExpenseEntry struct {
956 | XMLName xml.Name `xml:"http://replicon.com/ PutExpenseCodesAllowingExpenseEntry"`
957 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
958 | ExpenseCodeUris *string `xml:"http://replicon.com/ expenseCodeUris"`
959 | }
960 |
961 | type PutExpenseCodesAllowingExpenseEntryResponse struct {
962 | XMLName xml.Name `xml:"http://replicon.com/ PutExpenseCodesAllowingExpenseEntryResponse"`
963 | }
964 |
965 | type PutProject struct {
966 | XMLName xml.Name `xml:"http://replicon.com/ PutProject"`
967 | Project *ProjectParameter1 `xml:"http://replicon.com/ project"`
968 | }
969 |
970 | type PutProjectInfo struct {
971 | XMLName xml.Name `xml:"http://replicon.com/ PutProjectInfo"`
972 | Target *ProjectTargetParameter1 `xml:"http://replicon.com/ target"`
973 | ProjectInfo *ProjectInfoParameter1 `xml:"http://replicon.com/ projectInfo"`
974 | }
975 |
976 | type PutProjectInfoResponse struct {
977 | XMLName xml.Name `xml:"http://replicon.com/ PutProjectInfoResponse"`
978 | PutProjectInfoResult *ProjectReference1 `xml:"http://replicon.com/ PutProjectInfoResult"`
979 | }
980 |
981 | type PutProjectResponse struct {
982 | XMLName xml.Name `xml:"http://replicon.com/ PutProjectResponse"`
983 | PutProjectResult *ProjectReference1 `xml:"http://replicon.com/ PutProjectResult"`
984 | }
985 |
986 | type PutProjectTeamMemberAssignments struct {
987 | XMLName xml.Name `xml:"http://replicon.com/ PutProjectTeamMemberAssignments"`
988 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
989 | ResourceUris *string `xml:"http://replicon.com/ resourceUris"`
990 | }
991 |
992 | type PutProjectTeamMemberAssignmentsResponse struct {
993 | XMLName xml.Name `xml:"http://replicon.com/ PutProjectTeamMemberAssignmentsResponse"`
994 | }
995 |
996 | type PutTask struct {
997 | XMLName xml.Name `xml:"http://replicon.com/ PutTask"`
998 | Project *ProjectTargetParameter1 `xml:"http://replicon.com/ project"`
999 | Task *TaskParameter1 `xml:"http://replicon.com/ task"`
1000 | }
1001 |
1002 | type PutTaskAssignmentsForResource struct {
1003 | XMLName xml.Name `xml:"http://replicon.com/ PutTaskAssignmentsForResource"`
1004 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1005 | ResourceUri *string `xml:"http://replicon.com/ resourceUri"`
1006 | TaskUris *string `xml:"http://replicon.com/ taskUris"`
1007 | }
1008 |
1009 | type PutTaskAssignmentsForResourceResponse struct {
1010 | XMLName xml.Name `xml:"http://replicon.com/ PutTaskAssignmentsForResourceResponse"`
1011 | }
1012 |
1013 | type PutTaskHierarchy struct {
1014 | XMLName xml.Name `xml:"http://replicon.com/ PutTaskHierarchy"`
1015 | Project *ProjectTargetParameter1 `xml:"http://replicon.com/ project"`
1016 | TaskHierarchy *ArrayOfTaskHierarchyParameter1 `xml:"http://replicon.com/ taskHierarchy"`
1017 | }
1018 |
1019 | type PutTaskHierarchyResponse struct {
1020 | XMLName xml.Name `xml:"http://replicon.com/ PutTaskHierarchyResponse"`
1021 | PutTaskHierarchyResult *ArrayOfTaskHierarchyPutResults1 `xml:"http://replicon.com/ PutTaskHierarchyResult"`
1022 | }
1023 |
1024 | type PutTaskResponse struct {
1025 | XMLName xml.Name `xml:"http://replicon.com/ PutTaskResponse"`
1026 | PutTaskResult *TaskReference1 `xml:"http://replicon.com/ PutTaskResult"`
1027 | }
1028 |
1029 | type ResourcePlaceholderReference1 struct {
1030 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1031 | Uri *string `xml:"http://replicon.com/ uri"`
1032 | }
1033 |
1034 | type ResourcePlaceholderTargetParameter1 struct {
1035 | Index *int32 `xml:"http://replicon.com/ index"`
1036 | ParameterCorrelationId *string `xml:"http://replicon.com/ parameterCorrelationId"`
1037 | ProjectRole *ProjectRoleTargetParameter1 `xml:"http://replicon.com/ projectRole"`
1038 | Uri *string `xml:"http://replicon.com/ uri"`
1039 | }
1040 |
1041 | type ResourceReference1 struct {
1042 | Department *DepartmentReference1 `xml:"http://replicon.com/ department"`
1043 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1044 | ResourcePlaceholder *ResourcePlaceholderReference1 `xml:"http://replicon.com/ resourcePlaceholder"`
1045 | ResourceType *ResourceTypeDetails1 `xml:"http://replicon.com/ resourceType"`
1046 | Slug *string `xml:"http://replicon.com/ slug"`
1047 | Uri *string `xml:"http://replicon.com/ uri"`
1048 | User *UserReference1 `xml:"http://replicon.com/ user"`
1049 | }
1050 |
1051 | type ResourceTargetParameter1 struct {
1052 | Department *DepartmentTargetParameter1 `xml:"http://replicon.com/ department"`
1053 | Placeholder *ResourcePlaceholderTargetParameter1 `xml:"http://replicon.com/ placeholder"`
1054 | ResourcePlaceholderParameterCorrelationId *string `xml:"http://replicon.com/ resourcePlaceholderParameterCorrelationId"`
1055 | Uri *string `xml:"http://replicon.com/ uri"`
1056 | User *UserTargetParameter1 `xml:"http://replicon.com/ user"`
1057 | }
1058 |
1059 | type ResourceTypeDetails1 struct {
1060 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1061 | Uri *string `xml:"http://replicon.com/ uri"`
1062 | }
1063 |
1064 | type SlugNotFoundError1 struct {
1065 | Slug *string `xml:"http://replicon.com/ slug"`
1066 | }
1067 |
1068 | type TaskDuration1 struct {
1069 | Hours *int32 `xml:"http://replicon.com/ hours"`
1070 | Minutes *int32 `xml:"http://replicon.com/ minutes"`
1071 | }
1072 |
1073 | type TaskHierarchyParameter1 struct {
1074 | ChildTasks *ArrayOfTaskHierarchyParameter1 `xml:"http://replicon.com/ childTasks"`
1075 | Task *TaskParameter1 `xml:"http://replicon.com/ task"`
1076 | }
1077 |
1078 | type TaskHierarchyPutResults1 struct {
1079 | ChildTasks *ArrayOfTaskHierarchyPutResults1 `xml:"http://replicon.com/ childTasks"`
1080 | ParameterCorrelationId *string `xml:"http://replicon.com/ parameterCorrelationId"`
1081 | Task *TaskReference1 `xml:"http://replicon.com/ task"`
1082 | }
1083 |
1084 | type TaskParameter1 struct {
1085 | AssignedResources *ArrayOfResourceTargetParameter1 `xml:"http://replicon.com/ assignedResources"`
1086 | Code *string `xml:"http://replicon.com/ code"`
1087 | CostTypeUri *string `xml:"http://replicon.com/ costTypeUri"`
1088 | CustomFieldValues *ArrayOfCustomFieldValueParameter1 `xml:"http://replicon.com/ customFieldValues"`
1089 | Description *string `xml:"http://replicon.com/ description"`
1090 | EstimatedCost *MoneyParameter2 `xml:"http://replicon.com/ estimatedCost"`
1091 | EstimatedHours *TaskDuration1 `xml:"http://replicon.com/ estimatedHours"`
1092 | IsClosed *bool `xml:"http://replicon.com/ isClosed"`
1093 | IsTimeEntryAllowed *bool `xml:"http://replicon.com/ isTimeEntryAllowed"`
1094 | Name *string `xml:"http://replicon.com/ name"`
1095 | PercentCompleted *int32 `xml:"http://replicon.com/ percentCompleted"`
1096 | Target *TaskTargetParameter1 `xml:"http://replicon.com/ target"`
1097 | TimeEntryDateRange *DateRangeParameter1 `xml:"http://replicon.com/ timeEntryDateRange"`
1098 | }
1099 |
1100 | type TaskReference1 struct {
1101 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1102 | Uri *string `xml:"http://replicon.com/ uri"`
1103 | }
1104 |
1105 | type TaskResourceAssignmentDetails1 struct {
1106 | Assignments *ArrayOfProjectTeamMemberDetails1 `xml:"http://replicon.com/ assignments"`
1107 | TaskUri *string `xml:"http://replicon.com/ taskUri"`
1108 | }
1109 |
1110 | type TaskTargetParameter1 struct {
1111 | Name *string `xml:"http://replicon.com/ name"`
1112 | ParameterCorrelationId *string `xml:"http://replicon.com/ parameterCorrelationId"`
1113 | Parent *TaskTargetParameter1 `xml:"http://replicon.com/ parent"`
1114 | Uri *string `xml:"http://replicon.com/ uri"`
1115 | }
1116 |
1117 | type TimeAndExpenseEntryTypeReference1 struct {
1118 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1119 | Uri *string `xml:"http://replicon.com/ uri"`
1120 | }
1121 |
1122 | type UpdateAllowTimeEntryAgainstTasksOnly struct {
1123 | XMLName xml.Name `xml:"http://replicon.com/ UpdateAllowTimeEntryAgainstTasksOnly"`
1124 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1125 | AllowTimeEntryAgainstTasksOnly *bool `xml:"http://replicon.com/ allowTimeEntryAgainstTasksOnly"`
1126 | }
1127 |
1128 | type UpdateAllowTimeEntryAgainstTasksOnlyResponse struct {
1129 | XMLName xml.Name `xml:"http://replicon.com/ UpdateAllowTimeEntryAgainstTasksOnlyResponse"`
1130 | }
1131 |
1132 | type UpdateCode struct {
1133 | XMLName xml.Name `xml:"http://replicon.com/ UpdateCode"`
1134 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1135 | Code *string `xml:"http://replicon.com/ code"`
1136 | }
1137 |
1138 | type UpdateCodeResponse struct {
1139 | XMLName xml.Name `xml:"http://replicon.com/ UpdateCodeResponse"`
1140 | }
1141 |
1142 | type UpdateCostType struct {
1143 | XMLName xml.Name `xml:"http://replicon.com/ UpdateCostType"`
1144 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1145 | CostTypeUri *string `xml:"http://replicon.com/ costTypeUri"`
1146 | }
1147 |
1148 | type UpdateCostTypeResponse struct {
1149 | XMLName xml.Name `xml:"http://replicon.com/ UpdateCostTypeResponse"`
1150 | }
1151 |
1152 | type UpdateDescription struct {
1153 | XMLName xml.Name `xml:"http://replicon.com/ UpdateDescription"`
1154 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1155 | Description *string `xml:"http://replicon.com/ description"`
1156 | }
1157 |
1158 | type UpdateDescriptionResponse struct {
1159 | XMLName xml.Name `xml:"http://replicon.com/ UpdateDescriptionResponse"`
1160 | }
1161 |
1162 | type UpdateEstimatedCost struct {
1163 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimatedCost"`
1164 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1165 | EstimatedCost *MoneyParameter1 `xml:"http://replicon.com/ estimatedCost"`
1166 | }
1167 |
1168 | type UpdateEstimatedCostResponse struct {
1169 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimatedCostResponse"`
1170 | }
1171 |
1172 | type UpdateEstimatedExpenses struct {
1173 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimatedExpenses"`
1174 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1175 | Estimate *MoneyParameter1 `xml:"http://replicon.com/ estimate"`
1176 | }
1177 |
1178 | type UpdateEstimatedExpensesResponse struct {
1179 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimatedExpensesResponse"`
1180 | }
1181 |
1182 | type UpdateEstimatedHours struct {
1183 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimatedHours"`
1184 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1185 | EstimatedHours *TaskDuration1 `xml:"http://replicon.com/ estimatedHours"`
1186 | }
1187 |
1188 | type UpdateEstimatedHoursResponse struct {
1189 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimatedHoursResponse"`
1190 | }
1191 |
1192 | type UpdateEstimationMode struct {
1193 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimationMode"`
1194 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1195 | EstimationModeUri *string `xml:"http://replicon.com/ estimationModeUri"`
1196 | }
1197 |
1198 | type UpdateEstimationModeResponse struct {
1199 | XMLName xml.Name `xml:"http://replicon.com/ UpdateEstimationModeResponse"`
1200 | }
1201 |
1202 | type UpdateExpenseCodeAllowingExpenseEntry struct {
1203 | XMLName xml.Name `xml:"http://replicon.com/ UpdateExpenseCodeAllowingExpenseEntry"`
1204 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1205 | ExpenseCodeUri *string `xml:"http://replicon.com/ expenseCodeUri"`
1206 | Allowed *bool `xml:"http://replicon.com/ allowed"`
1207 | }
1208 |
1209 | type UpdateExpenseCodeAllowingExpenseEntryResponse struct {
1210 | XMLName xml.Name `xml:"http://replicon.com/ UpdateExpenseCodeAllowingExpenseEntryResponse"`
1211 | }
1212 |
1213 | type UpdateName struct {
1214 | XMLName xml.Name `xml:"http://replicon.com/ UpdateName"`
1215 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1216 | Name *string `xml:"http://replicon.com/ name"`
1217 | }
1218 |
1219 | type UpdateNameResponse struct {
1220 | XMLName xml.Name `xml:"http://replicon.com/ UpdateNameResponse"`
1221 | }
1222 |
1223 | type UpdatePercentComplete struct {
1224 | XMLName xml.Name `xml:"http://replicon.com/ UpdatePercentComplete"`
1225 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1226 | PercentComplete *int32 `xml:"http://replicon.com/ percentComplete"`
1227 | }
1228 |
1229 | type UpdatePercentCompleteResponse struct {
1230 | XMLName xml.Name `xml:"http://replicon.com/ UpdatePercentCompleteResponse"`
1231 | }
1232 |
1233 | type UpdateProgram struct {
1234 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProgram"`
1235 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1236 | ProgramUri *string `xml:"http://replicon.com/ programUri"`
1237 | }
1238 |
1239 | type UpdateProgramResponse struct {
1240 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProgramResponse"`
1241 | }
1242 |
1243 | type UpdateProjectCodeSettingForNewProjectsAsAutoincrementingNumber struct {
1244 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectCodeSettingForNewProjectsAsAutoincrementingNumber"`
1245 | StartingProjectCode *uint32 `xml:"http://replicon.com/ startingProjectCode"`
1246 | }
1247 |
1248 | type UpdateProjectCodeSettingForNewProjectsAsAutoincrementingNumberResponse struct {
1249 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectCodeSettingForNewProjectsAsAutoincrementingNumberResponse"`
1250 | }
1251 |
1252 | type UpdateProjectCodeSettingForNewProjectsAsUserEntered struct {
1253 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectCodeSettingForNewProjectsAsUserEntered"`
1254 | }
1255 |
1256 | type UpdateProjectCodeSettingForNewProjectsAsUserEnteredResponse struct {
1257 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectCodeSettingForNewProjectsAsUserEnteredResponse"`
1258 | }
1259 |
1260 | type UpdateProjectLeader struct {
1261 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectLeader"`
1262 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1263 | UserUri *string `xml:"http://replicon.com/ userUri"`
1264 | }
1265 |
1266 | type UpdateProjectLeaderApprovalIsRequired struct {
1267 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectLeaderApprovalIsRequired"`
1268 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1269 | IsRequired *bool `xml:"http://replicon.com/ isRequired"`
1270 | }
1271 |
1272 | type UpdateProjectLeaderApprovalIsRequiredResponse struct {
1273 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectLeaderApprovalIsRequiredResponse"`
1274 | }
1275 |
1276 | type UpdateProjectLeaderResponse struct {
1277 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectLeaderResponse"`
1278 | }
1279 |
1280 | type UpdateProjectNameFormatForNewUsers struct {
1281 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectNameFormatForNewUsers"`
1282 | ProjectNameFormatUri *string `xml:"http://replicon.com/ projectNameFormatUri"`
1283 | }
1284 |
1285 | type UpdateProjectNameFormatForNewUsersResponse struct {
1286 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectNameFormatForNewUsersResponse"`
1287 | }
1288 |
1289 | type UpdateProjectNameFormatForUser struct {
1290 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectNameFormatForUser"`
1291 | UserUri *string `xml:"http://replicon.com/ userUri"`
1292 | ProjectNameFormatUri *string `xml:"http://replicon.com/ projectNameFormatUri"`
1293 | }
1294 |
1295 | type UpdateProjectNameFormatForUserResponse struct {
1296 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectNameFormatForUserResponse"`
1297 | }
1298 |
1299 | type UpdateProjectTeamMemberAssignment struct {
1300 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectTeamMemberAssignment"`
1301 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1302 | ResourceUri *string `xml:"http://replicon.com/ resourceUri"`
1303 | ProjectTeamMemberAssignmentOptionUri *string `xml:"http://replicon.com/ projectTeamMemberAssignmentOptionUri"`
1304 | }
1305 |
1306 | type UpdateProjectTeamMemberAssignmentResponse struct {
1307 | XMLName xml.Name `xml:"http://replicon.com/ UpdateProjectTeamMemberAssignmentResponse"`
1308 | }
1309 |
1310 | type UpdateStatus struct {
1311 | XMLName xml.Name `xml:"http://replicon.com/ UpdateStatus"`
1312 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1313 | ProjectStatusUri *string `xml:"http://replicon.com/ projectStatusUri"`
1314 | }
1315 |
1316 | type UpdateStatusResponse struct {
1317 | XMLName xml.Name `xml:"http://replicon.com/ UpdateStatusResponse"`
1318 | }
1319 |
1320 | type UpdateTimeEntryDateRange struct {
1321 | XMLName xml.Name `xml:"http://replicon.com/ UpdateTimeEntryDateRange"`
1322 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1323 | DateRange *DateRangeParameter1 `xml:"http://replicon.com/ dateRange"`
1324 | }
1325 |
1326 | type UpdateTimeEntryDateRangeResponse struct {
1327 | XMLName xml.Name `xml:"http://replicon.com/ UpdateTimeEntryDateRangeResponse"`
1328 | }
1329 |
1330 | type UriError1 struct {
1331 | Uri *string `xml:"http://replicon.com/ uri"`
1332 | }
1333 |
1334 | type UserReference1 struct {
1335 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1336 | LoginName *string `xml:"http://replicon.com/ loginName"`
1337 | Slug *string `xml:"http://replicon.com/ slug"`
1338 | Uri *string `xml:"http://replicon.com/ uri"`
1339 | }
1340 |
1341 | type UserTargetParameter1 struct {
1342 | LoginName *string `xml:"http://replicon.com/ loginName"`
1343 | Uri *string `xml:"http://replicon.com/ uri"`
1344 | }
1345 |
1346 | type Validate struct {
1347 | XMLName xml.Name `xml:"http://replicon.com/ Validate"`
1348 | ProjectUri *string `xml:"http://replicon.com/ projectUri"`
1349 | }
1350 |
1351 | type ValidateResponse struct {
1352 | XMLName xml.Name `xml:"http://replicon.com/ ValidateResponse"`
1353 | ValidateResult *ValidationResultsSummary1 `xml:"http://replicon.com/ ValidateResult"`
1354 | }
1355 |
1356 | type ValidationContextSummary1 struct {
1357 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1358 | ParameterCorrelationId *string `xml:"http://replicon.com/ parameterCorrelationId"`
1359 | Uri *string `xml:"http://replicon.com/ uri"`
1360 | }
1361 |
1362 | type ValidationError1 struct {
1363 | Notifications *ArrayOfValidationNotificationSummary1 `xml:"http://replicon.com/ notifications"`
1364 | }
1365 |
1366 | type ValidationNotificationSummary1 struct {
1367 | Context *ValidationContextSummary1 `xml:"http://replicon.com/ context"`
1368 | DisplayText *string `xml:"http://replicon.com/ displayText"`
1369 | FailureUri *string `xml:"http://replicon.com/ failureUri"`
1370 | SeverityUri *string `xml:"http://replicon.com/ severityUri"`
1371 | }
1372 |
1373 | type ValidationResultsSummary1 struct {
1374 | Notifications *ArrayOfValidationNotificationSummary1 `xml:"http://replicon.com/ notifications"`
1375 | }
1376 |
--------------------------------------------------------------------------------
/test-client/soap.go:
--------------------------------------------------------------------------------
1 | package main
2 |
3 | import (
4 | "bytes"
5 | "encoding/xml"
6 | "errors"
7 | "flag"
8 | "io"
9 | "net/http"
10 | )
11 |
12 | type SoapEnvelope struct {
13 | XMLName xml.Name `xml:"http://schemas.xmlsoap.org/soap/envelope/ Envelope"`
14 | EncodingStyle string `xml:"http://schemas.xmlsoap.org/soap/envelope/ encodingStyle,attr"`
15 | Body SoapBody `xml:"http://schemas.xmlsoap.org/soap/envelope/ Body"`
16 | }
17 |
18 | type SoapBody struct {
19 | Body interface{}
20 | }
21 |
22 | func CreateSoapEnvelope() *SoapEnvelope {
23 | retval := &SoapEnvelope{}
24 | retval.EncodingStyle = "http://schemas.xmlsoap.org/soap/encoding/"
25 | return retval
26 | }
27 |
28 | func main() {
29 | var username = flag.String("username", "", "HTTP basic auth username")
30 | var password = flag.String("password", "", "HTTP basic auth password")
31 | flag.Parse()
32 |
33 | buffer := &bytes.Buffer{}
34 | requestEnvelope := CreateSoapEnvelope()
35 | requestEnvelope.Body.Body = GetAllProjects{}
36 | encoder := xml.NewEncoder(buffer)
37 | err := encoder.Encode(requestEnvelope)
38 | if err != nil {
39 | println("Error encoding document:", err.Error())
40 | return
41 | }
42 |
43 | // FIXME: encoding
44 | client := http.Client{}
45 | req, err := http.NewRequest("POST", "http://na2.replicon.com/services/ProjectService1.svc/soap", buffer)
46 | if err != nil {
47 | println("Error creating HTTP request:", err.Error())
48 | return
49 | }
50 | if username != nil && password != nil && *username != "" && *password != "" {
51 | println("Autheticating")
52 | req.SetBasicAuth(*username, *password)
53 | }
54 | req.Header.Add("SOAPAction", "\"http://replicon.com/IProjectService1/GetAllProjects\"")
55 | req.Header.Add("Content-Type", "text/xml")
56 | resp, err := client.Do(req)
57 | if err != nil {
58 | println("Error POSTing HTTP request:", err.Error())
59 | return
60 | }
61 |
62 | if resp.StatusCode != 200 {
63 | println("Error:", resp.Status)
64 | }
65 | // FIXME: check Content-Type
66 | // FIXME: encoding
67 |
68 | // responseEnvelope := SoapEnvelope{}
69 | bodyElement, err := DecodeResponseBody(resp.Body)
70 | if err != nil {
71 | println("Error decoding body:", err.Error())
72 | return
73 | }
74 | println("Decoded body!")
75 |
76 | if bodyElement.GetAllProjectsResult == nil {
77 | println("GetAllProjectsResult is nil")
78 | return
79 | }
80 |
81 | for _, project := range bodyElement.GetAllProjectsResult.ProjectReference1 {
82 | println("Project:", *project.Slug, *project.Uri, *project.DisplayText)
83 | }
84 | }
85 |
86 | func DecodeResponseBody(body io.Reader) (*GetAllProjectsResponse, error) {
87 | decoder := xml.NewDecoder(body)
88 | nextElementIsBody := false
89 | for {
90 | token, err := decoder.Token()
91 | if err == io.EOF {
92 | break
93 | } else if err != nil {
94 | return nil, err
95 | }
96 | switch startElement := token.(type) {
97 | case xml.StartElement:
98 | if nextElementIsBody {
99 | responseBody := GetAllProjectsResponse{}
100 | err = decoder.DecodeElement(&responseBody, &startElement)
101 | if err != nil {
102 | return nil, err
103 | }
104 | return &responseBody, nil
105 | }
106 | if startElement.Name.Space == "http://schemas.xmlsoap.org/soap/envelope/" && startElement.Name.Local == "Body" {
107 | nextElementIsBody = true
108 | }
109 | }
110 | }
111 |
112 | return nil, errors.New("Did not find SOAP body element")
113 | }
114 |
--------------------------------------------------------------------------------