diff --git a/_gen/generate-components/main.go b/_gen/generate-components/main.go index 7ce1a66e9..99df78639 100644 --- a/_gen/generate-components/main.go +++ b/_gen/generate-components/main.go @@ -4,12 +4,13 @@ import ( "bytes" "flag" "fmt" - "github.com/quickfixgo/quickfix/_gen" - "github.com/quickfixgo/quickfix/datadictionary" "os" "path" "strconv" "strings" + + "github.com/quickfixgo/quickfix/_gen" + "github.com/quickfixgo/quickfix/datadictionary" ) var ( @@ -57,38 +58,43 @@ type group struct { field *datadictionary.FieldDef } -func collectGroups(parent string, field *datadictionary.FieldDef, groups []group) []group { - if !field.IsGroup() { - return groups - } +func collectGroups(parent string, part datadictionary.MessagePart, groups []group) []group { + switch field := part.(type) { + case *datadictionary.FieldDef: + if !field.IsGroup() { + return groups + } - groups = append(groups, group{parent, field}) - for _, childField := range field.ChildFields { - groups = collectGroups(field.Name, childField, groups) + groups = append(groups, group{parent, field}) + for _, childField := range field.Parts { + groups = collectGroups(field.Name(), childField, groups) + } } return groups } -func writeFieldDeclaration(field *datadictionary.FieldDef, componentName string) string { - switch { - case field.IsComponent(): - imports[fmt.Sprintf("github.com/quickfixgo/quickfix/%v/%v", pkg, strings.ToLower(field.Component.Name))] = true - case !field.IsGroup(): - goType := gen.FixFieldTypeToGoType(field.Type) - if goType == "time.Time" { - imports["time"] = true +func writeFieldDeclaration(part datadictionary.MessagePart, componentName string) string { + switch field := part.(type) { + case datadictionary.Component: + imports[fmt.Sprintf("github.com/quickfixgo/quickfix/%v/%v", pkg, strings.ToLower(field.Name()))] = true + case *datadictionary.FieldDef: + if !field.IsGroup() { + goType := gen.FixFieldTypeToGoType(field.Type) + if goType == "time.Time" { + imports["time"] = true + } } } - return gen.WriteFieldDeclaration(fixSpec.Major, fixSpec.Minor, field, componentName) + return gen.WriteFieldDeclaration(fixSpec.Major, fixSpec.Minor, part, componentName) } func genGroupDeclaration(field *datadictionary.FieldDef, parent string) (fileOut string) { - fileOut += fmt.Sprintf("//%v is a repeating group in %v\n", field.Name, parent) - fileOut += fmt.Sprintf("type %v struct {\n", field.Name) - for _, groupField := range field.ChildFields { - fileOut += writeFieldDeclaration(groupField, field.Name) + fileOut += fmt.Sprintf("//%v is a repeating group in %v\n", field.Name(), parent) + fileOut += fmt.Sprintf("type %v struct {\n", field.Name()) + for _, groupField := range field.Parts { + fileOut += writeFieldDeclaration(groupField, field.Name()) } fileOut += "}\n" @@ -96,7 +102,7 @@ func genGroupDeclaration(field *datadictionary.FieldDef, parent string) (fileOut return } -func genGroupDeclarations(name string, fields []*datadictionary.FieldDef) (fileOut string) { +func genGroupDeclarations(name string, fields []datadictionary.MessagePart) (fileOut string) { groups := []group{} for _, field := range fields { groups = collectGroups(name, field, groups) @@ -113,10 +119,10 @@ func genHeader(header *datadictionary.MessageDef) { imports = make(map[string]bool) //delay field output to determine imports - delayOut := genGroupDeclarations("Header", header.FieldsInDeclarationOrder) + delayOut := genGroupDeclarations("Header", header.Parts) delayOut += fmt.Sprintf("//Header is the %v Header type\n", pkg) delayOut += "type Header struct {\n" - for _, field := range header.FieldsInDeclarationOrder { + for _, field := range header.Parts { delayOut += writeFieldDeclaration(field, "Header") } delayOut += "}\n" @@ -126,7 +132,7 @@ func genHeader(header *datadictionary.MessageDef) { fileOut += delayOut writer := new(bytes.Buffer) - if err := gen.WriteFieldSetters(writer, "Header", header.FieldsInDeclarationOrder); err != nil { + if err := gen.WriteFieldSetters(writer, "Header", header.Parts); err != nil { panic(err) } fileOut += writer.String() @@ -139,13 +145,13 @@ func genTrailer(trailer *datadictionary.MessageDef) { fileOut := packageString() fileOut += fmt.Sprintf("//Trailer is the %v Trailer type\n", pkg) fileOut += "type Trailer struct {\n" - for _, field := range trailer.FieldsInDeclarationOrder { + for _, field := range trailer.Parts { fileOut += writeFieldDeclaration(field, "Trailer") } fileOut += "}\n" writer := new(bytes.Buffer) - if err := gen.WriteFieldSetters(writer, "Trailer", trailer.FieldsInDeclarationOrder); err != nil { + if err := gen.WriteFieldSetters(writer, "Trailer", trailer.Parts); err != nil { panic(err) } fileOut += writer.String() @@ -153,14 +159,14 @@ func genTrailer(trailer *datadictionary.MessageDef) { gen.WriteFile(path.Join(pkg, "trailer.go"), fileOut) } -func genComponent(name string, component *datadictionary.Component) { +func genComponent(name string, component *datadictionary.ComponentType) { imports = make(map[string]bool) //delay output to determine imports - delayOut := genGroupDeclarations(name, component.Fields) + delayOut := genGroupDeclarations(name, component.Parts) delayOut += fmt.Sprintf("//%v is a %v Component\n", name, pkg) delayOut += fmt.Sprintf("type %v struct {\n", name) - for _, field := range component.Fields { + for _, field := range component.Parts { delayOut += writeFieldDeclaration(field, name) } delayOut += "}\n" @@ -174,9 +180,9 @@ func genComponent(name string, component *datadictionary.Component) { gen.WriteFile(path.Join(pkg, strings.ToLower(name), name+".go"), fileOut) } -func genComponentSetters(component *datadictionary.Component) string { +func genComponentSetters(component *datadictionary.ComponentType) string { writer := new(bytes.Buffer) - if err := gen.WriteFieldSetters(writer, component.Name, component.Fields); err != nil { + if err := gen.WriteFieldSetters(writer, component.Name(), component.Parts); err != nil { panic(err) } @@ -216,7 +222,7 @@ func main() { genTrailer(fixSpec.Trailer) } - for name, component := range fixSpec.Components { + for name, component := range fixSpec.ComponentTypes { genComponent(name, component) } } diff --git a/_gen/generate-fields/main.go b/_gen/generate-fields/main.go index 24a025b3b..926b36a26 100644 --- a/_gen/generate-fields/main.go +++ b/_gen/generate-fields/main.go @@ -3,10 +3,11 @@ package main import ( "flag" "fmt" - "github.com/quickfixgo/quickfix/_gen" - "github.com/quickfixgo/quickfix/datadictionary" "os" "sort" + + "github.com/quickfixgo/quickfix/_gen" + "github.com/quickfixgo/quickfix/datadictionary" ) var ( @@ -138,16 +139,16 @@ func genFields() { fmt.Printf("Unknown type '%v' for tag '%v'\n", field.Type, tag) } - fileOut += fmt.Sprintf("//%vField is a %v field\n", field.Name, field.Type) - fileOut += fmt.Sprintf("type %vField struct { quickfix.%v }\n", field.Name, baseType) - fileOut += fmt.Sprintf("//Tag returns tag.%v (%v)\n", field.Name, field.Tag) - fileOut += fmt.Sprintf("func (f %vField) Tag() quickfix.Tag {return tag.%v}\n", field.Name, field.Name) + fileOut += fmt.Sprintf("//%vField is a %v field\n", field.Name(), field.Type) + fileOut += fmt.Sprintf("type %vField struct { quickfix.%v }\n", field.Name(), baseType) + fileOut += fmt.Sprintf("//Tag returns tag.%v (%v)\n", field.Name(), field.Tag) + fileOut += fmt.Sprintf("func (f %vField) Tag() quickfix.Tag {return tag.%v}\n", field.Name(), field.Name()) switch goType { case "bool", "int", "float64", "string": - fileOut += fmt.Sprintf("//New%v returns a new %vField initialized with val\n", field.Name, field.Name) - fileOut += fmt.Sprintf("func New%v(val %v) *%vField {\n", field.Name, goType, field.Name) - fileOut += fmt.Sprintf("return &%vField{quickfix.%v(val)}\n", field.Name, baseType) + fileOut += fmt.Sprintf("//New%v returns a new %vField initialized with val\n", field.Name(), field.Name()) + fileOut += fmt.Sprintf("func New%v(val %v) *%vField {\n", field.Name(), goType, field.Name()) + fileOut += fmt.Sprintf("return &%vField{quickfix.%v(val)}\n", field.Name(), baseType) fileOut += "}\n" } } @@ -188,9 +189,9 @@ func main() { } for _, field := range spec.FieldTypeByTag { - fieldMap[field.Name] = int(field.Tag) + fieldMap[field.Name()] = int(field.Tag) - if oldField, ok := fieldTypeMap[field.Name]; ok { + if oldField, ok := fieldTypeMap[field.Name()]; ok { //merge old enums with new if len(oldField.Enums) > 0 && field.Enums == nil { field.Enums = make(map[string]datadictionary.Enum) @@ -214,7 +215,7 @@ func main() { } } - fieldTypeMap[field.Name] = field + fieldTypeMap[field.Name()] = field } } diff --git a/_gen/generate-messages/main.go b/_gen/generate-messages/main.go index ac5b210c5..c62e01622 100644 --- a/_gen/generate-messages/main.go +++ b/_gen/generate-messages/main.go @@ -4,13 +4,14 @@ import ( "bytes" "flag" "fmt" - "github.com/quickfixgo/quickfix/_gen" - "github.com/quickfixgo/quickfix/datadictionary" "os" "path" "sort" "strconv" "strings" + + "github.com/quickfixgo/quickfix/_gen" + "github.com/quickfixgo/quickfix/datadictionary" ) var ( @@ -55,31 +56,33 @@ import( return fileOut } -func writeFieldDeclaration(field *datadictionary.FieldDef, componentName string) string { - switch { - case field.IsComponent(): - imports[fmt.Sprintf("github.com/quickfixgo/quickfix/%v/%v", pkg, strings.ToLower(field.Component.Name))] = true - case !field.IsGroup(): - goType := gen.FixFieldTypeToGoType(field.Type) - if goType == "time.Time" { - imports["time"] = true +func writeFieldDeclaration(part datadictionary.MessagePart, componentName string) string { + switch field := part.(type) { + case datadictionary.Component: + imports[fmt.Sprintf("github.com/quickfixgo/quickfix/%v/%v", pkg, strings.ToLower(field.Name()))] = true + case *datadictionary.FieldDef: + if !field.IsGroup() { + goType := gen.FixFieldTypeToGoType(field.Type) + if goType == "time.Time" { + imports["time"] = true + } } } - return gen.WriteFieldDeclaration(fixSpec.Major, fixSpec.Minor, field, componentName) + return gen.WriteFieldDeclaration(fixSpec.Major, fixSpec.Minor, part, componentName) } func genGroupDeclaration(field *datadictionary.FieldDef, parent string) (fileOut string) { - fileOut += fmt.Sprintf("//%v is a repeating group in %v\n", field.Name, parent) - fileOut += fmt.Sprintf("type %v struct {\n", field.Name) - for _, groupField := range field.ChildFields { - fileOut += writeFieldDeclaration(groupField, field.Name) + fileOut += fmt.Sprintf("//%v is a repeating group in %v\n", field.Name(), parent) + fileOut += fmt.Sprintf("type %v struct {\n", field.Name()) + for _, groupField := range field.Parts { + fileOut += writeFieldDeclaration(groupField, field.Name()) } fileOut += "}\n" writer := new(bytes.Buffer) - if err := gen.WriteFieldSetters(writer, field.Name, field.ChildFields); err != nil { + if err := gen.WriteFieldSetters(writer, field.Name(), field.Parts); err != nil { panic(err) } fileOut += writer.String() @@ -93,14 +96,17 @@ type group struct { field *datadictionary.FieldDef } -func collectGroups(parent string, field *datadictionary.FieldDef, groups []group) []group { - if !field.IsGroup() { - return groups - } +func collectGroups(parent string, part datadictionary.MessagePart, groups []group) []group { + switch field := part.(type) { + case *datadictionary.FieldDef: + if !field.IsGroup() { + return groups + } - groups = append(groups, group{parent, field}) - for _, childField := range field.ChildFields { - groups = collectGroups(field.Name, childField, groups) + groups = append(groups, group{parent, field}) + for _, childField := range field.Parts { + groups = collectGroups(field.Name(), childField, groups) + } } return groups @@ -108,7 +114,7 @@ func collectGroups(parent string, field *datadictionary.FieldDef, groups []group func genGroupDeclarations(msg *datadictionary.MessageDef) (fileOut string) { groups := []group{} - for _, field := range msg.FieldsInDeclarationOrder { + for _, field := range msg.Parts { groups = collectGroups(msg.Name, field, groups) } @@ -128,12 +134,12 @@ func headerTrailerPkg() string { return pkg } -func genMessage(msg *datadictionary.MessageDef, requiredFields []*datadictionary.FieldDef) string { +func genMessage(msg *datadictionary.MessageDef) string { fileOut := fmt.Sprintf("//Message is a %v FIX Message\n", msg.Name) fileOut += "type Message struct {\n" fileOut += fmt.Sprintf("FIXMsgType string `fix:\"%v\"`\n", msg.MsgType) fileOut += fmt.Sprintf("%v.Header\n", headerTrailerPkg()) - for _, field := range msg.FieldsInDeclarationOrder { + for _, field := range msg.Parts { fileOut += writeFieldDeclaration(field, msg.Name) } fileOut += fmt.Sprintf("%v.Trailer\n", headerTrailerPkg()) @@ -146,7 +152,7 @@ func genMessage(msg *datadictionary.MessageDef, requiredFields []*datadictionary func genMessageSetters(msg *datadictionary.MessageDef) string { writer := new(bytes.Buffer) - if err := gen.WriteFieldSetters(writer, "Message", msg.FieldsInDeclarationOrder); err != nil { + if err := gen.WriteFieldSetters(writer, "Message", msg.Parts); err != nil { panic(err) } return writer.String() @@ -185,13 +191,6 @@ func Route(router RouteOut) (string,string,quickfix.MessageRoute) { } func genMessagePkg(msg *datadictionary.MessageDef) { - requiredFields := make([]*datadictionary.FieldDef, 0, len(msg.FieldsInDeclarationOrder)) - for _, field := range msg.FieldsInDeclarationOrder { - if field.Required { - requiredFields = append(requiredFields, field) - } - } - pkgName := strings.ToLower(msg.Name) imports = make(map[string]bool) @@ -201,7 +200,7 @@ func genMessagePkg(msg *datadictionary.MessageDef) { //run through group and message declarations to collect required imports first delayOut := "" delayOut += genGroupDeclarations(msg) - delayOut += genMessage(msg, requiredFields) + delayOut += genMessage(msg) fileOut += genMessageImports() fileOut += delayOut diff --git a/_gen/helpers.go b/_gen/helpers.go index 7fec916c0..6b22bef25 100644 --- a/_gen/helpers.go +++ b/_gen/helpers.go @@ -2,11 +2,12 @@ package gen import ( "fmt" - "github.com/quickfixgo/quickfix/datadictionary" "io" "strconv" "strings" "text/template" + + "github.com/quickfixgo/quickfix/datadictionary" ) var fieldSetterTemplate *template.Template @@ -23,62 +24,63 @@ func (m *{{.Receiver}}) Set{{.Name}}(v {{ if .IsGroup}}[]{{.Name}}{{else}}{{fixF {{- end}}}`)) } -//WriteFieldSetters generates setters appropriate for Messages, Components and Repeating Groups -func WriteFieldSetters(writer io.Writer, receiver string, fields []*datadictionary.FieldDef) error { +//WriteFieldSetters generates setters appropriate for Messages, Components or Repeating Groups +func WriteFieldSetters(writer io.Writer, receiver string, parts []datadictionary.MessagePart) error { type setter struct { Receiver string *datadictionary.FieldDef } - for _, field := range fields { - if field.IsComponent() { - continue - } - - if err := fieldSetterTemplate.Execute(writer, setter{receiver, field}); err != nil { - return err + for _, part := range parts { + switch field := part.(type) { + case *datadictionary.FieldDef: + if err := fieldSetterTemplate.Execute(writer, setter{receiver, field}); err != nil { + return err + } } } return nil } -func WriteFieldDeclaration(fixSpecMajor int, fixSpecMinor int, field *datadictionary.FieldDef, componentName string) (s string) { - if field.IsComponent() { - s += fmt.Sprintf("//%v Component\n", field.Component.Name) - s += fmt.Sprintf("%v.%v\n", strings.ToLower(field.Component.Name), field.Component.Name) +func WriteFieldDeclaration(fixSpecMajor int, fixSpecMinor int, part datadictionary.MessagePart, componentName string) (s string) { + switch field := part.(type) { + case datadictionary.Component: + s += fmt.Sprintf("//%v Component\n", field.Name()) + s += fmt.Sprintf("%v.%v\n", strings.ToLower(field.Name()), field.Name()) return - } - - if field.Required { - s += fmt.Sprintf("//%v is a required field for %v.\n", field.Name, componentName) - } else { - s += fmt.Sprintf("//%v is a non-required field for %v.\n", field.Name, componentName) - } - if field.IsGroup() { - if field.Required { - s += fmt.Sprintf("%v []%v `fix:\"%v\"`\n", field.Name, field.Name, field.Tag) + case *datadictionary.FieldDef: + if field.Required() { + s += fmt.Sprintf("//%v is a required field for %v.\n", field.Name(), componentName) } else { - s += fmt.Sprintf("%v []%v `fix:\"%v,omitempty\"`\n", field.Name, field.Name, field.Tag) + s += fmt.Sprintf("//%v is a non-required field for %v.\n", field.Name(), componentName) } - return - } - goType := FixFieldTypeToGoType(field.Type) - fixTags := strconv.Itoa(field.Tag) - if field.Tag == 8 { - if fixSpecMajor == 4 { - fixTags = fmt.Sprintf("%v,default=FIX.%v.%v", fixTags, fixSpecMajor, fixSpecMinor) - } else { - fixTags = fixTags + ",default=FIXT.1.1" + if field.IsGroup() { + if field.Required() { + s += fmt.Sprintf("%v []%v `fix:\"%v\"`\n", field.Name(), field.Name(), field.Tag) + } else { + s += fmt.Sprintf("%v []%v `fix:\"%v,omitempty\"`\n", field.Name(), field.Name(), field.Tag) + } + return } - } - if field.Required { - s += fmt.Sprintf("%v %v `fix:\"%v\"`\n", field.Name, goType, fixTags) - } else { - s += fmt.Sprintf("%v *%v `fix:\"%v\"`\n", field.Name, goType, fixTags) + goType := FixFieldTypeToGoType(field.Type) + fixTags := strconv.Itoa(field.Tag) + if field.Tag == 8 { + if fixSpecMajor == 4 { + fixTags = fmt.Sprintf("%v,default=FIX.%v.%v", fixTags, fixSpecMajor, fixSpecMinor) + } else { + fixTags = fixTags + ",default=FIXT.1.1" + } + } + + if field.Required() { + s += fmt.Sprintf("%v %v `fix:\"%v\"`\n", field.Name(), goType, fixTags) + } else { + s += fmt.Sprintf("%v *%v `fix:\"%v\"`\n", field.Name(), goType, fixTags) + } } return } diff --git a/datadictionary/build.go b/datadictionary/build.go index 72d84c511..dabc25d58 100644 --- a/datadictionary/build.go +++ b/datadictionary/build.go @@ -40,8 +40,8 @@ func (b *builder) build(doc *XMLDoc) (*DataDictionary, error) { return b.dict, nil } -func (b builder) findOrBuildComponent(xmlMember *XMLComponentMember) (*Component, error) { - if comp, preBuilt := b.dict.Components[xmlMember.Name]; preBuilt { +func (b builder) findOrBuildComponentType(xmlMember *XMLComponentMember) (*ComponentType, error) { + if comp, preBuilt := b.dict.ComponentTypes[xmlMember.Name]; preBuilt { return comp, nil } @@ -52,39 +52,45 @@ func (b builder) findOrBuildComponent(xmlMember *XMLComponentMember) (*Component return nil, newUnknownComponent(xmlMember.Name) } - var comp *Component + var comp *ComponentType var err error - if comp, err = b.buildComponent(xmlComp); err != nil { + if comp, err = b.buildComponentType(xmlComp); err != nil { return nil, err } - b.dict.Components[xmlMember.Name] = comp + b.dict.ComponentTypes[xmlMember.Name] = comp return comp, nil } -func (b builder) buildComponent(xmlComponent *XMLComponent) (*Component, error) { - c := &Component{Name: xmlComponent.Name, Fields: make([]*FieldDef, 0)} +func (b builder) buildComponentType(xmlComponent *XMLComponent) (*ComponentType, error) { + c := &ComponentType{name: xmlComponent.Name} for _, member := range xmlComponent.Members { if member.XMLName.Local == "component" { - var childComponent *Component + var childComponentType *ComponentType var err error - if childComponent, err = b.findOrBuildComponent(member); err != nil { + if childComponentType, err = b.findOrBuildComponentType(member); err != nil { return nil, err } - for _, childField := range childComponent.Fields { - c.Fields = append(c.Fields, childField) + childComponent := Component{ + ComponentType: childComponentType, + required: (member.Required == "Y"), } + + c.Parts = append(c.Parts, childComponent) + c.Fields = append(c.Fields, childComponentType.Fields...) } else { var field *FieldDef var err error if field, err = b.buildFieldDef(member); err != nil { return nil, err } + c.Fields = append(c.Fields, field) + c.Parts = append(c.Parts, field) } } @@ -92,16 +98,16 @@ func (b builder) buildComponent(xmlComponent *XMLComponent) (*Component, error) } func (b builder) buildComponents() error { - b.dict.Components = make(map[string]*Component) + b.dict.ComponentTypes = make(map[string]*ComponentType) for _, c := range b.doc.Components { - if _, allReadyBuilt := b.dict.Components[c.Name]; !allReadyBuilt { - var builtComponent *Component + if _, allReadyBuilt := b.dict.ComponentTypes[c.Name]; !allReadyBuilt { + var builtComponent *ComponentType var err error - if builtComponent, err = b.buildComponent(c); err != nil { + if builtComponent, err = b.buildComponentType(c); err != nil { return err } - b.dict.Components[c.Name] = builtComponent + b.dict.ComponentTypes[c.Name] = builtComponent } } @@ -124,15 +130,14 @@ func (b builder) buildMessageDefs() error { func (b builder) buildMessageDef(xmlMessage *XMLComponent) (*MessageDef, error) { m := &MessageDef{Name: xmlMessage.Name, MsgType: xmlMessage.MsgType} m.Fields = make(map[int]*FieldDef) - m.FieldsInDeclarationOrder = make([]*FieldDef, 0) m.RequiredTags = make(TagSet) m.Tags = make(TagSet) for _, member := range xmlMessage.Members { if member.XMLName.Local == "component" { var ok bool - var comp *Component - if comp, ok = b.dict.Components[member.Name]; !ok { + var comp *ComponentType + if comp, ok = b.dict.ComponentTypes[member.Name]; !ok { return nil, newUnknownComponent(member.Name) } @@ -140,7 +145,7 @@ func (b builder) buildMessageDef(xmlMessage *XMLComponent) (*MessageDef, error) m.Fields[f.Tag] = f } - m.FieldsInDeclarationOrder = append(m.FieldsInDeclarationOrder, &FieldDef{Component: comp}) + m.Parts = append(m.Parts, Component{ComponentType: comp, required: (member.Required == "Y")}) } else { var field *FieldDef var err error @@ -148,7 +153,7 @@ func (b builder) buildMessageDef(xmlMessage *XMLComponent) (*MessageDef, error) return nil, err } m.Fields[field.Tag] = field - m.FieldsInDeclarationOrder = append(m.FieldsInDeclarationOrder, field) + m.Parts = append(m.Parts, field) } } @@ -158,7 +163,7 @@ func (b builder) buildMessageDef(xmlMessage *XMLComponent) (*MessageDef, error) m.Tags.Add(t) } - if f.Required { + if f.Required() { m.RequiredTags.Add(f.Tag) for _, t := range f.requiredChildTags() { m.RequiredTags.Add(t) @@ -170,17 +175,25 @@ func (b builder) buildMessageDef(xmlMessage *XMLComponent) (*MessageDef, error) } func (b builder) buildGroupFieldDef(xmlField *XMLComponentMember, groupFieldType *FieldType) (*FieldDef, error) { - fields := make([]*FieldDef, 0, len(xmlField.Members)) + var parts []MessagePart + var fields []*FieldDef for _, member := range xmlField.Members { if member.XMLName.Local == "component" { var err error - var comp *Component - if comp, err = b.findOrBuildComponent(member); err != nil { + var comp *ComponentType + if comp, err = b.findOrBuildComponentType(member); err != nil { return nil, err } - fields = append(fields, &FieldDef{Component: comp}) + parts = append(parts, Component{ComponentType: comp, required: (member.Required == "Y")}) + //FIXME: set fields + for _, f := range comp.Parts { + switch field := f.(type) { + case *FieldDef: + fields = append(fields, field) + } + } } else { var f *FieldDef @@ -188,11 +201,12 @@ func (b builder) buildGroupFieldDef(xmlField *XMLComponentMember, groupFieldType if f, err = b.buildFieldDef(member); err != nil { return nil, err } + parts = append(parts, f) fields = append(fields, f) } } - return &FieldDef{FieldType: groupFieldType, Required: (xmlField.Required == "Y"), ChildFields: fields}, nil + return &FieldDef{FieldType: groupFieldType, required: (xmlField.Required == "Y"), Parts: parts, ChildFields: fields}, nil } func (b builder) buildFieldDef(xmlField *XMLComponentMember) (*FieldDef, error) { @@ -208,7 +222,7 @@ func (b builder) buildFieldDef(xmlField *XMLComponentMember) (*FieldDef, error) return f, err } - return &FieldDef{FieldType: fieldType, Required: (xmlField.Required == "Y"), ChildFields: make([]*FieldDef, 0)}, nil + return &FieldDef{FieldType: fieldType, required: (xmlField.Required == "Y")}, nil } func (b builder) buildFieldTypes() { @@ -217,12 +231,12 @@ func (b builder) buildFieldTypes() { for _, f := range b.doc.Fields { field := buildFieldType(f) b.dict.FieldTypeByTag[field.Tag] = field - b.dict.FieldTypeByName[field.Name] = field + b.dict.FieldTypeByName[field.Name()] = field } } func buildFieldType(xmlField *XMLField) *FieldType { - field := FieldType{Name: xmlField.Name, Tag: xmlField.Number, Type: xmlField.Type} + field := FieldType{name: xmlField.Name, Tag: xmlField.Number, Type: xmlField.Type} if len(xmlField.Values) > 0 { field.Enums = make(map[string]Enum) diff --git a/datadictionary/datadictionary.go b/datadictionary/datadictionary.go index 23bfa55cf..cfd63fddb 100644 --- a/datadictionary/datadictionary.go +++ b/datadictionary/datadictionary.go @@ -15,17 +15,30 @@ type DataDictionary struct { FieldTypeByTag map[int]*FieldType FieldTypeByName map[string]*FieldType Messages map[string]*MessageDef - Components map[string]*Component + ComponentTypes map[string]*ComponentType Header *MessageDef Trailer *MessageDef } -//Component is a grouping of fields. -type Component struct { - Name string +//MessagePart can represent a Field, Repeating Group, or Component +type MessagePart interface { + Name() string + Required() bool +} + +//ComponentType is a grouping of fields. +type ComponentType struct { + name string + // MessageParts in declaration order contained in this component + Parts []MessagePart + //All fields contained in this component. Includes fields encapsulated in + //components of this component Fields []*FieldDef } +//Name returns the name of this component type +func (c ComponentType) Name() string { return c.name } + //TagSet is set for tags. type TagSet map[int]struct{} @@ -34,30 +47,38 @@ func (t TagSet) Add(tag int) { t[tag] = struct{}{} } +//Component is a Component as it appears in a given MessageDef +type Component struct { + *ComponentType + required bool +} + +//Required returns true if this component is required for the containing +//MessageDef +func (c Component) Required() bool { return c.required } + //FieldDef models a field or component belonging to a message. type FieldDef struct { *FieldType - Component *Component - Required bool + required bool + + Parts []MessagePart ChildFields []*FieldDef } +//Required returns true if this FieldDef is required for the containing +//MessageDef +func (f FieldDef) Required() bool { return f.required } + //IsGroup is true if the field is a repeating group. func (f FieldDef) IsGroup() bool { return len(f.ChildFields) > 0 } -func (f FieldDef) IsComponent() bool { - return f.Component != nil -} - func (f FieldDef) childTags() []int { tags := make([]int, 0, len(f.ChildFields)) for _, f := range f.ChildFields { - if f.IsComponent() { - continue - } tags = append(tags, f.Tag) for _, t := range f.childTags() { tags = append(tags, t) @@ -68,10 +89,10 @@ func (f FieldDef) childTags() []int { } func (f FieldDef) requiredChildTags() []int { - tags := make([]int, 0) + var tags []int for _, f := range f.ChildFields { - if !f.Required { + if !f.Required() { continue } @@ -86,12 +107,24 @@ func (f FieldDef) requiredChildTags() []int { //FieldType holds information relating to a field. Includes Tag, type, and enums, if defined. type FieldType struct { - Name string + name string Tag int Type string Enums map[string]Enum } +//NewFieldType returns a pointer to an initialized FieldType +func NewFieldType(name string, tag int, fixType string) *FieldType { + return &FieldType{ + name: name, + Tag: tag, + Type: fixType, + } +} + +//Name returns the name for this FieldType +func (f FieldType) Name() string { return f.name } + //Enum is a container for value and description. type Enum struct { Value string @@ -100,10 +133,12 @@ type Enum struct { //MessageDef can apply to header, trailer, or body of a FIX Message. type MessageDef struct { - Name string - MsgType string - Fields map[int]*FieldDef - FieldsInDeclarationOrder []*FieldDef + Name string + MsgType string + Fields map[int]*FieldDef + //Parts are the MessageParts of contained in this MessageDef in declaration + //order + Parts []MessagePart RequiredTags TagSet Tags TagSet diff --git a/datadictionary/datadictionary_test.go b/datadictionary/datadictionary_test.go index b0a2477cf..299130154 100644 --- a/datadictionary/datadictionary_test.go +++ b/datadictionary/datadictionary_test.go @@ -36,7 +36,7 @@ func dict() (*DataDictionary, error) { func TestComponents(t *testing.T) { d, _ := dict() - if _, ok := d.Components["SpreadOrBenchmarkCurveData"]; ok != true { + if _, ok := d.ComponentTypes["SpreadOrBenchmarkCurveData"]; ok != true { t.Error("Component not found") } } @@ -61,8 +61,8 @@ func TestFieldsByTag(t *testing.T) { t.Errorf("%v not found", test.Tag) } - if f.Name != test.Name { - t.Errorf("Expected %v got %v", test.Name, f.Name) + if f.Name() != test.Name { + t.Errorf("Expected %v got %v", test.Name, f.Name()) } if f.Type != test.Type { diff --git a/fix44/underlyinginstrument/UnderlyingInstrument.go b/fix44/underlyinginstrument/UnderlyingInstrument.go index f20d6b7e7..7c6317ab2 100644 --- a/fix44/underlyinginstrument/UnderlyingInstrument.go +++ b/fix44/underlyinginstrument/UnderlyingInstrument.go @@ -1,5 +1,9 @@ package underlyinginstrument +import ( + "github.com/quickfixgo/quickfix/fix44/underlyingstipulations" +) + //NoUnderlyingSecurityAltID is a repeating group in UnderlyingInstrument type NoUnderlyingSecurityAltID struct { //UnderlyingSecurityAltID is a non-required field for NoUnderlyingSecurityAltID. @@ -8,14 +12,6 @@ type NoUnderlyingSecurityAltID struct { UnderlyingSecurityAltIDSource *string `fix:"459"` } -//NoUnderlyingStips is a repeating group in UnderlyingInstrument -type NoUnderlyingStips struct { - //UnderlyingStipType is a non-required field for NoUnderlyingStips. - UnderlyingStipType *string `fix:"888"` - //UnderlyingStipValue is a non-required field for NoUnderlyingStips. - UnderlyingStipValue *string `fix:"889"` -} - //UnderlyingInstrument is a fix44 Component type UnderlyingInstrument struct { //UnderlyingSymbol is a non-required field for UnderlyingInstrument. @@ -108,8 +104,8 @@ type UnderlyingInstrument struct { UnderlyingCurrentValue *float64 `fix:"885"` //UnderlyingEndValue is a non-required field for UnderlyingInstrument. UnderlyingEndValue *float64 `fix:"886"` - //NoUnderlyingStips is a non-required field for UnderlyingInstrument. - NoUnderlyingStips []NoUnderlyingStips `fix:"887,omitempty"` + //UnderlyingStipulations Component + underlyingstipulations.UnderlyingStipulations } func (m *UnderlyingInstrument) SetUnderlyingSymbol(v string) { m.UnderlyingSymbol = &v } @@ -169,14 +165,13 @@ func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDescLen(v int) { func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDesc(v string) { m.EncodedUnderlyingSecurityDesc = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } -func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } -func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } -func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } -func (m *UnderlyingInstrument) SetNoUnderlyingStips(v []NoUnderlyingStips) { m.NoUnderlyingStips = v } +func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } +func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } +func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } +func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } +func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } diff --git a/fix50/instrument/Instrument.go b/fix50/instrument/Instrument.go index e0016ede6..d43345fce 100644 --- a/fix50/instrument/Instrument.go +++ b/fix50/instrument/Instrument.go @@ -1,41 +1,11 @@ package instrument import ( - "github.com/quickfixgo/quickfix/fix50/instrumentptyssubgrp" + "github.com/quickfixgo/quickfix/fix50/evntgrp" + "github.com/quickfixgo/quickfix/fix50/instrumentparties" + "github.com/quickfixgo/quickfix/fix50/secaltidgrp" ) -//NoSecurityAltID is a repeating group in Instrument -type NoSecurityAltID struct { - //SecurityAltID is a non-required field for NoSecurityAltID. - SecurityAltID *string `fix:"455"` - //SecurityAltIDSource is a non-required field for NoSecurityAltID. - SecurityAltIDSource *string `fix:"456"` -} - -//NoEvents is a repeating group in Instrument -type NoEvents struct { - //EventType is a non-required field for NoEvents. - EventType *int `fix:"865"` - //EventDate is a non-required field for NoEvents. - EventDate *string `fix:"866"` - //EventPx is a non-required field for NoEvents. - EventPx *float64 `fix:"867"` - //EventText is a non-required field for NoEvents. - EventText *string `fix:"868"` -} - -//NoInstrumentParties is a repeating group in Instrument -type NoInstrumentParties struct { - //InstrumentPartyID is a non-required field for NoInstrumentParties. - InstrumentPartyID *string `fix:"1019"` - //InstrumentPartyIDSource is a non-required field for NoInstrumentParties. - InstrumentPartyIDSource *string `fix:"1050"` - //InstrumentPartyRole is a non-required field for NoInstrumentParties. - InstrumentPartyRole *int `fix:"1051"` - //InstrumentPtysSubGrp Component - instrumentptyssubgrp.InstrumentPtysSubGrp -} - //Instrument is a fix50 Component type Instrument struct { //Symbol is a non-required field for Instrument. @@ -46,8 +16,8 @@ type Instrument struct { SecurityID *string `fix:"48"` //SecurityIDSource is a non-required field for Instrument. SecurityIDSource *string `fix:"22"` - //NoSecurityAltID is a non-required field for Instrument. - NoSecurityAltID []NoSecurityAltID `fix:"454,omitempty"` + //SecAltIDGrp Component + secaltidgrp.SecAltIDGrp //Product is a non-required field for Instrument. Product *int `fix:"460"` //CFICode is a non-required field for Instrument. @@ -116,8 +86,8 @@ type Instrument struct { CPProgram *int `fix:"875"` //CPRegType is a non-required field for Instrument. CPRegType *string `fix:"876"` - //NoEvents is a non-required field for Instrument. - NoEvents []NoEvents `fix:"864,omitempty"` + //EvntGrp Component + evntgrp.EvntGrp //DatedDate is a non-required field for Instrument. DatedDate *string `fix:"873"` //InterestAccrualDate is a non-required field for Instrument. @@ -138,8 +108,8 @@ type Instrument struct { PositionLimit *int `fix:"970"` //NTPositionLimit is a non-required field for Instrument. NTPositionLimit *int `fix:"971"` - //NoInstrumentParties is a non-required field for Instrument. - NoInstrumentParties []NoInstrumentParties `fix:"1018,omitempty"` + //InstrumentParties Component + instrumentparties.InstrumentParties //UnitOfMeasure is a non-required field for Instrument. UnitOfMeasure *string `fix:"996"` //TimeUnit is a non-required field for Instrument. @@ -148,57 +118,54 @@ type Instrument struct { MaturityTime *string `fix:"1079"` } -func (m *Instrument) SetSymbol(v string) { m.Symbol = &v } -func (m *Instrument) SetSymbolSfx(v string) { m.SymbolSfx = &v } -func (m *Instrument) SetSecurityID(v string) { m.SecurityID = &v } -func (m *Instrument) SetSecurityIDSource(v string) { m.SecurityIDSource = &v } -func (m *Instrument) SetNoSecurityAltID(v []NoSecurityAltID) { m.NoSecurityAltID = v } -func (m *Instrument) SetProduct(v int) { m.Product = &v } -func (m *Instrument) SetCFICode(v string) { m.CFICode = &v } -func (m *Instrument) SetSecurityType(v string) { m.SecurityType = &v } -func (m *Instrument) SetSecuritySubType(v string) { m.SecuritySubType = &v } -func (m *Instrument) SetMaturityMonthYear(v string) { m.MaturityMonthYear = &v } -func (m *Instrument) SetMaturityDate(v string) { m.MaturityDate = &v } -func (m *Instrument) SetCouponPaymentDate(v string) { m.CouponPaymentDate = &v } -func (m *Instrument) SetIssueDate(v string) { m.IssueDate = &v } -func (m *Instrument) SetRepoCollateralSecurityType(v int) { m.RepoCollateralSecurityType = &v } -func (m *Instrument) SetRepurchaseTerm(v int) { m.RepurchaseTerm = &v } -func (m *Instrument) SetRepurchaseRate(v float64) { m.RepurchaseRate = &v } -func (m *Instrument) SetFactor(v float64) { m.Factor = &v } -func (m *Instrument) SetCreditRating(v string) { m.CreditRating = &v } -func (m *Instrument) SetInstrRegistry(v string) { m.InstrRegistry = &v } -func (m *Instrument) SetCountryOfIssue(v string) { m.CountryOfIssue = &v } -func (m *Instrument) SetStateOrProvinceOfIssue(v string) { m.StateOrProvinceOfIssue = &v } -func (m *Instrument) SetLocaleOfIssue(v string) { m.LocaleOfIssue = &v } -func (m *Instrument) SetRedemptionDate(v string) { m.RedemptionDate = &v } -func (m *Instrument) SetStrikePrice(v float64) { m.StrikePrice = &v } -func (m *Instrument) SetStrikeCurrency(v string) { m.StrikeCurrency = &v } -func (m *Instrument) SetOptAttribute(v string) { m.OptAttribute = &v } -func (m *Instrument) SetContractMultiplier(v float64) { m.ContractMultiplier = &v } -func (m *Instrument) SetCouponRate(v float64) { m.CouponRate = &v } -func (m *Instrument) SetSecurityExchange(v string) { m.SecurityExchange = &v } -func (m *Instrument) SetIssuer(v string) { m.Issuer = &v } -func (m *Instrument) SetEncodedIssuerLen(v int) { m.EncodedIssuerLen = &v } -func (m *Instrument) SetEncodedIssuer(v string) { m.EncodedIssuer = &v } -func (m *Instrument) SetSecurityDesc(v string) { m.SecurityDesc = &v } -func (m *Instrument) SetEncodedSecurityDescLen(v int) { m.EncodedSecurityDescLen = &v } -func (m *Instrument) SetEncodedSecurityDesc(v string) { m.EncodedSecurityDesc = &v } -func (m *Instrument) SetPool(v string) { m.Pool = &v } -func (m *Instrument) SetContractSettlMonth(v string) { m.ContractSettlMonth = &v } -func (m *Instrument) SetCPProgram(v int) { m.CPProgram = &v } -func (m *Instrument) SetCPRegType(v string) { m.CPRegType = &v } -func (m *Instrument) SetNoEvents(v []NoEvents) { m.NoEvents = v } -func (m *Instrument) SetDatedDate(v string) { m.DatedDate = &v } -func (m *Instrument) SetInterestAccrualDate(v string) { m.InterestAccrualDate = &v } -func (m *Instrument) SetSecurityStatus(v string) { m.SecurityStatus = &v } -func (m *Instrument) SetSettleOnOpenFlag(v string) { m.SettleOnOpenFlag = &v } -func (m *Instrument) SetInstrmtAssignmentMethod(v string) { m.InstrmtAssignmentMethod = &v } -func (m *Instrument) SetStrikeMultiplier(v float64) { m.StrikeMultiplier = &v } -func (m *Instrument) SetStrikeValue(v float64) { m.StrikeValue = &v } -func (m *Instrument) SetMinPriceIncrement(v float64) { m.MinPriceIncrement = &v } -func (m *Instrument) SetPositionLimit(v int) { m.PositionLimit = &v } -func (m *Instrument) SetNTPositionLimit(v int) { m.NTPositionLimit = &v } -func (m *Instrument) SetNoInstrumentParties(v []NoInstrumentParties) { m.NoInstrumentParties = v } -func (m *Instrument) SetUnitOfMeasure(v string) { m.UnitOfMeasure = &v } -func (m *Instrument) SetTimeUnit(v string) { m.TimeUnit = &v } -func (m *Instrument) SetMaturityTime(v string) { m.MaturityTime = &v } +func (m *Instrument) SetSymbol(v string) { m.Symbol = &v } +func (m *Instrument) SetSymbolSfx(v string) { m.SymbolSfx = &v } +func (m *Instrument) SetSecurityID(v string) { m.SecurityID = &v } +func (m *Instrument) SetSecurityIDSource(v string) { m.SecurityIDSource = &v } +func (m *Instrument) SetProduct(v int) { m.Product = &v } +func (m *Instrument) SetCFICode(v string) { m.CFICode = &v } +func (m *Instrument) SetSecurityType(v string) { m.SecurityType = &v } +func (m *Instrument) SetSecuritySubType(v string) { m.SecuritySubType = &v } +func (m *Instrument) SetMaturityMonthYear(v string) { m.MaturityMonthYear = &v } +func (m *Instrument) SetMaturityDate(v string) { m.MaturityDate = &v } +func (m *Instrument) SetCouponPaymentDate(v string) { m.CouponPaymentDate = &v } +func (m *Instrument) SetIssueDate(v string) { m.IssueDate = &v } +func (m *Instrument) SetRepoCollateralSecurityType(v int) { m.RepoCollateralSecurityType = &v } +func (m *Instrument) SetRepurchaseTerm(v int) { m.RepurchaseTerm = &v } +func (m *Instrument) SetRepurchaseRate(v float64) { m.RepurchaseRate = &v } +func (m *Instrument) SetFactor(v float64) { m.Factor = &v } +func (m *Instrument) SetCreditRating(v string) { m.CreditRating = &v } +func (m *Instrument) SetInstrRegistry(v string) { m.InstrRegistry = &v } +func (m *Instrument) SetCountryOfIssue(v string) { m.CountryOfIssue = &v } +func (m *Instrument) SetStateOrProvinceOfIssue(v string) { m.StateOrProvinceOfIssue = &v } +func (m *Instrument) SetLocaleOfIssue(v string) { m.LocaleOfIssue = &v } +func (m *Instrument) SetRedemptionDate(v string) { m.RedemptionDate = &v } +func (m *Instrument) SetStrikePrice(v float64) { m.StrikePrice = &v } +func (m *Instrument) SetStrikeCurrency(v string) { m.StrikeCurrency = &v } +func (m *Instrument) SetOptAttribute(v string) { m.OptAttribute = &v } +func (m *Instrument) SetContractMultiplier(v float64) { m.ContractMultiplier = &v } +func (m *Instrument) SetCouponRate(v float64) { m.CouponRate = &v } +func (m *Instrument) SetSecurityExchange(v string) { m.SecurityExchange = &v } +func (m *Instrument) SetIssuer(v string) { m.Issuer = &v } +func (m *Instrument) SetEncodedIssuerLen(v int) { m.EncodedIssuerLen = &v } +func (m *Instrument) SetEncodedIssuer(v string) { m.EncodedIssuer = &v } +func (m *Instrument) SetSecurityDesc(v string) { m.SecurityDesc = &v } +func (m *Instrument) SetEncodedSecurityDescLen(v int) { m.EncodedSecurityDescLen = &v } +func (m *Instrument) SetEncodedSecurityDesc(v string) { m.EncodedSecurityDesc = &v } +func (m *Instrument) SetPool(v string) { m.Pool = &v } +func (m *Instrument) SetContractSettlMonth(v string) { m.ContractSettlMonth = &v } +func (m *Instrument) SetCPProgram(v int) { m.CPProgram = &v } +func (m *Instrument) SetCPRegType(v string) { m.CPRegType = &v } +func (m *Instrument) SetDatedDate(v string) { m.DatedDate = &v } +func (m *Instrument) SetInterestAccrualDate(v string) { m.InterestAccrualDate = &v } +func (m *Instrument) SetSecurityStatus(v string) { m.SecurityStatus = &v } +func (m *Instrument) SetSettleOnOpenFlag(v string) { m.SettleOnOpenFlag = &v } +func (m *Instrument) SetInstrmtAssignmentMethod(v string) { m.InstrmtAssignmentMethod = &v } +func (m *Instrument) SetStrikeMultiplier(v float64) { m.StrikeMultiplier = &v } +func (m *Instrument) SetStrikeValue(v float64) { m.StrikeValue = &v } +func (m *Instrument) SetMinPriceIncrement(v float64) { m.MinPriceIncrement = &v } +func (m *Instrument) SetPositionLimit(v int) { m.PositionLimit = &v } +func (m *Instrument) SetNTPositionLimit(v int) { m.NTPositionLimit = &v } +func (m *Instrument) SetUnitOfMeasure(v string) { m.UnitOfMeasure = &v } +func (m *Instrument) SetTimeUnit(v string) { m.TimeUnit = &v } +func (m *Instrument) SetMaturityTime(v string) { m.MaturityTime = &v } diff --git a/fix50/instrumentextension/InstrumentExtension.go b/fix50/instrumentextension/InstrumentExtension.go index 4e823a133..5ff426dbe 100644 --- a/fix50/instrumentextension/InstrumentExtension.go +++ b/fix50/instrumentextension/InstrumentExtension.go @@ -1,12 +1,8 @@ package instrumentextension -//NoInstrAttrib is a repeating group in InstrumentExtension -type NoInstrAttrib struct { - //InstrAttribType is a non-required field for NoInstrAttrib. - InstrAttribType *int `fix:"871"` - //InstrAttribValue is a non-required field for NoInstrAttrib. - InstrAttribValue *string `fix:"872"` -} +import ( + "github.com/quickfixgo/quickfix/fix50/attrbgrp" +) //InstrumentExtension is a fix50 Component type InstrumentExtension struct { @@ -14,10 +10,9 @@ type InstrumentExtension struct { DeliveryForm *int `fix:"668"` //PctAtRisk is a non-required field for InstrumentExtension. PctAtRisk *float64 `fix:"869"` - //NoInstrAttrib is a non-required field for InstrumentExtension. - NoInstrAttrib []NoInstrAttrib `fix:"870,omitempty"` + //AttrbGrp Component + attrbgrp.AttrbGrp } -func (m *InstrumentExtension) SetDeliveryForm(v int) { m.DeliveryForm = &v } -func (m *InstrumentExtension) SetPctAtRisk(v float64) { m.PctAtRisk = &v } -func (m *InstrumentExtension) SetNoInstrAttrib(v []NoInstrAttrib) { m.NoInstrAttrib = v } +func (m *InstrumentExtension) SetDeliveryForm(v int) { m.DeliveryForm = &v } +func (m *InstrumentExtension) SetPctAtRisk(v float64) { m.PctAtRisk = &v } diff --git a/fix50/instrumentleg/InstrumentLeg.go b/fix50/instrumentleg/InstrumentLeg.go index 0a9d36775..1ad52a64b 100644 --- a/fix50/instrumentleg/InstrumentLeg.go +++ b/fix50/instrumentleg/InstrumentLeg.go @@ -1,12 +1,8 @@ package instrumentleg -//NoLegSecurityAltID is a repeating group in InstrumentLeg -type NoLegSecurityAltID struct { - //LegSecurityAltID is a non-required field for NoLegSecurityAltID. - LegSecurityAltID *string `fix:"605"` - //LegSecurityAltIDSource is a non-required field for NoLegSecurityAltID. - LegSecurityAltIDSource *string `fix:"606"` -} +import ( + "github.com/quickfixgo/quickfix/fix50/legsecaltidgrp" +) //InstrumentLeg is a fix50 Component type InstrumentLeg struct { @@ -18,8 +14,8 @@ type InstrumentLeg struct { LegSecurityID *string `fix:"602"` //LegSecurityIDSource is a non-required field for InstrumentLeg. LegSecurityIDSource *string `fix:"603"` - //NoLegSecurityAltID is a non-required field for InstrumentLeg. - NoLegSecurityAltID []NoLegSecurityAltID `fix:"604,omitempty"` + //LegSecAltIDGrp Component + legsecaltidgrp.LegSecAltIDGrp //LegProduct is a non-required field for InstrumentLeg. LegProduct *int `fix:"607"` //LegCFICode is a non-required field for InstrumentLeg. @@ -100,47 +96,46 @@ type InstrumentLeg struct { LegTimeUnit *string `fix:"1001"` } -func (m *InstrumentLeg) SetLegSymbol(v string) { m.LegSymbol = &v } -func (m *InstrumentLeg) SetLegSymbolSfx(v string) { m.LegSymbolSfx = &v } -func (m *InstrumentLeg) SetLegSecurityID(v string) { m.LegSecurityID = &v } -func (m *InstrumentLeg) SetLegSecurityIDSource(v string) { m.LegSecurityIDSource = &v } -func (m *InstrumentLeg) SetNoLegSecurityAltID(v []NoLegSecurityAltID) { m.NoLegSecurityAltID = v } -func (m *InstrumentLeg) SetLegProduct(v int) { m.LegProduct = &v } -func (m *InstrumentLeg) SetLegCFICode(v string) { m.LegCFICode = &v } -func (m *InstrumentLeg) SetLegSecurityType(v string) { m.LegSecurityType = &v } -func (m *InstrumentLeg) SetLegSecuritySubType(v string) { m.LegSecuritySubType = &v } -func (m *InstrumentLeg) SetLegMaturityMonthYear(v string) { m.LegMaturityMonthYear = &v } -func (m *InstrumentLeg) SetLegMaturityDate(v string) { m.LegMaturityDate = &v } -func (m *InstrumentLeg) SetLegCouponPaymentDate(v string) { m.LegCouponPaymentDate = &v } -func (m *InstrumentLeg) SetLegIssueDate(v string) { m.LegIssueDate = &v } -func (m *InstrumentLeg) SetLegRepoCollateralSecurityType(v int) { m.LegRepoCollateralSecurityType = &v } -func (m *InstrumentLeg) SetLegRepurchaseTerm(v int) { m.LegRepurchaseTerm = &v } -func (m *InstrumentLeg) SetLegRepurchaseRate(v float64) { m.LegRepurchaseRate = &v } -func (m *InstrumentLeg) SetLegFactor(v float64) { m.LegFactor = &v } -func (m *InstrumentLeg) SetLegCreditRating(v string) { m.LegCreditRating = &v } -func (m *InstrumentLeg) SetLegInstrRegistry(v string) { m.LegInstrRegistry = &v } -func (m *InstrumentLeg) SetLegCountryOfIssue(v string) { m.LegCountryOfIssue = &v } -func (m *InstrumentLeg) SetLegStateOrProvinceOfIssue(v string) { m.LegStateOrProvinceOfIssue = &v } -func (m *InstrumentLeg) SetLegLocaleOfIssue(v string) { m.LegLocaleOfIssue = &v } -func (m *InstrumentLeg) SetLegRedemptionDate(v string) { m.LegRedemptionDate = &v } -func (m *InstrumentLeg) SetLegStrikePrice(v float64) { m.LegStrikePrice = &v } -func (m *InstrumentLeg) SetLegStrikeCurrency(v string) { m.LegStrikeCurrency = &v } -func (m *InstrumentLeg) SetLegOptAttribute(v string) { m.LegOptAttribute = &v } -func (m *InstrumentLeg) SetLegContractMultiplier(v float64) { m.LegContractMultiplier = &v } -func (m *InstrumentLeg) SetLegCouponRate(v float64) { m.LegCouponRate = &v } -func (m *InstrumentLeg) SetLegSecurityExchange(v string) { m.LegSecurityExchange = &v } -func (m *InstrumentLeg) SetLegIssuer(v string) { m.LegIssuer = &v } -func (m *InstrumentLeg) SetEncodedLegIssuerLen(v int) { m.EncodedLegIssuerLen = &v } -func (m *InstrumentLeg) SetEncodedLegIssuer(v string) { m.EncodedLegIssuer = &v } -func (m *InstrumentLeg) SetLegSecurityDesc(v string) { m.LegSecurityDesc = &v } -func (m *InstrumentLeg) SetEncodedLegSecurityDescLen(v int) { m.EncodedLegSecurityDescLen = &v } -func (m *InstrumentLeg) SetEncodedLegSecurityDesc(v string) { m.EncodedLegSecurityDesc = &v } -func (m *InstrumentLeg) SetLegRatioQty(v float64) { m.LegRatioQty = &v } -func (m *InstrumentLeg) SetLegSide(v string) { m.LegSide = &v } -func (m *InstrumentLeg) SetLegCurrency(v string) { m.LegCurrency = &v } -func (m *InstrumentLeg) SetLegPool(v string) { m.LegPool = &v } -func (m *InstrumentLeg) SetLegDatedDate(v string) { m.LegDatedDate = &v } -func (m *InstrumentLeg) SetLegContractSettlMonth(v string) { m.LegContractSettlMonth = &v } -func (m *InstrumentLeg) SetLegInterestAccrualDate(v string) { m.LegInterestAccrualDate = &v } -func (m *InstrumentLeg) SetLegUnitOfMeasure(v string) { m.LegUnitOfMeasure = &v } -func (m *InstrumentLeg) SetLegTimeUnit(v string) { m.LegTimeUnit = &v } +func (m *InstrumentLeg) SetLegSymbol(v string) { m.LegSymbol = &v } +func (m *InstrumentLeg) SetLegSymbolSfx(v string) { m.LegSymbolSfx = &v } +func (m *InstrumentLeg) SetLegSecurityID(v string) { m.LegSecurityID = &v } +func (m *InstrumentLeg) SetLegSecurityIDSource(v string) { m.LegSecurityIDSource = &v } +func (m *InstrumentLeg) SetLegProduct(v int) { m.LegProduct = &v } +func (m *InstrumentLeg) SetLegCFICode(v string) { m.LegCFICode = &v } +func (m *InstrumentLeg) SetLegSecurityType(v string) { m.LegSecurityType = &v } +func (m *InstrumentLeg) SetLegSecuritySubType(v string) { m.LegSecuritySubType = &v } +func (m *InstrumentLeg) SetLegMaturityMonthYear(v string) { m.LegMaturityMonthYear = &v } +func (m *InstrumentLeg) SetLegMaturityDate(v string) { m.LegMaturityDate = &v } +func (m *InstrumentLeg) SetLegCouponPaymentDate(v string) { m.LegCouponPaymentDate = &v } +func (m *InstrumentLeg) SetLegIssueDate(v string) { m.LegIssueDate = &v } +func (m *InstrumentLeg) SetLegRepoCollateralSecurityType(v int) { m.LegRepoCollateralSecurityType = &v } +func (m *InstrumentLeg) SetLegRepurchaseTerm(v int) { m.LegRepurchaseTerm = &v } +func (m *InstrumentLeg) SetLegRepurchaseRate(v float64) { m.LegRepurchaseRate = &v } +func (m *InstrumentLeg) SetLegFactor(v float64) { m.LegFactor = &v } +func (m *InstrumentLeg) SetLegCreditRating(v string) { m.LegCreditRating = &v } +func (m *InstrumentLeg) SetLegInstrRegistry(v string) { m.LegInstrRegistry = &v } +func (m *InstrumentLeg) SetLegCountryOfIssue(v string) { m.LegCountryOfIssue = &v } +func (m *InstrumentLeg) SetLegStateOrProvinceOfIssue(v string) { m.LegStateOrProvinceOfIssue = &v } +func (m *InstrumentLeg) SetLegLocaleOfIssue(v string) { m.LegLocaleOfIssue = &v } +func (m *InstrumentLeg) SetLegRedemptionDate(v string) { m.LegRedemptionDate = &v } +func (m *InstrumentLeg) SetLegStrikePrice(v float64) { m.LegStrikePrice = &v } +func (m *InstrumentLeg) SetLegStrikeCurrency(v string) { m.LegStrikeCurrency = &v } +func (m *InstrumentLeg) SetLegOptAttribute(v string) { m.LegOptAttribute = &v } +func (m *InstrumentLeg) SetLegContractMultiplier(v float64) { m.LegContractMultiplier = &v } +func (m *InstrumentLeg) SetLegCouponRate(v float64) { m.LegCouponRate = &v } +func (m *InstrumentLeg) SetLegSecurityExchange(v string) { m.LegSecurityExchange = &v } +func (m *InstrumentLeg) SetLegIssuer(v string) { m.LegIssuer = &v } +func (m *InstrumentLeg) SetEncodedLegIssuerLen(v int) { m.EncodedLegIssuerLen = &v } +func (m *InstrumentLeg) SetEncodedLegIssuer(v string) { m.EncodedLegIssuer = &v } +func (m *InstrumentLeg) SetLegSecurityDesc(v string) { m.LegSecurityDesc = &v } +func (m *InstrumentLeg) SetEncodedLegSecurityDescLen(v int) { m.EncodedLegSecurityDescLen = &v } +func (m *InstrumentLeg) SetEncodedLegSecurityDesc(v string) { m.EncodedLegSecurityDesc = &v } +func (m *InstrumentLeg) SetLegRatioQty(v float64) { m.LegRatioQty = &v } +func (m *InstrumentLeg) SetLegSide(v string) { m.LegSide = &v } +func (m *InstrumentLeg) SetLegCurrency(v string) { m.LegCurrency = &v } +func (m *InstrumentLeg) SetLegPool(v string) { m.LegPool = &v } +func (m *InstrumentLeg) SetLegDatedDate(v string) { m.LegDatedDate = &v } +func (m *InstrumentLeg) SetLegContractSettlMonth(v string) { m.LegContractSettlMonth = &v } +func (m *InstrumentLeg) SetLegInterestAccrualDate(v string) { m.LegInterestAccrualDate = &v } +func (m *InstrumentLeg) SetLegUnitOfMeasure(v string) { m.LegUnitOfMeasure = &v } +func (m *InstrumentLeg) SetLegTimeUnit(v string) { m.LegTimeUnit = &v } diff --git a/fix50/settlinstructionsdata/SettlInstructionsData.go b/fix50/settlinstructionsdata/SettlInstructionsData.go index f55c4c195..0b3b41e40 100644 --- a/fix50/settlinstructionsdata/SettlInstructionsData.go +++ b/fix50/settlinstructionsdata/SettlInstructionsData.go @@ -1,19 +1,9 @@ package settlinstructionsdata import ( - "github.com/quickfixgo/quickfix/fix50/settlparties" + "github.com/quickfixgo/quickfix/fix50/dlvyinstgrp" ) -//NoDlvyInst is a repeating group in SettlInstructionsData -type NoDlvyInst struct { - //SettlInstSource is a non-required field for NoDlvyInst. - SettlInstSource *string `fix:"165"` - //DlvyInstType is a non-required field for NoDlvyInst. - DlvyInstType *string `fix:"787"` - //SettlParties Component - settlparties.SettlParties -} - //SettlInstructionsData is a fix50 Component type SettlInstructionsData struct { //SettlDeliveryType is a non-required field for SettlInstructionsData. @@ -24,12 +14,11 @@ type SettlInstructionsData struct { StandInstDbName *string `fix:"170"` //StandInstDbID is a non-required field for SettlInstructionsData. StandInstDbID *string `fix:"171"` - //NoDlvyInst is a non-required field for SettlInstructionsData. - NoDlvyInst []NoDlvyInst `fix:"85,omitempty"` + //DlvyInstGrp Component + dlvyinstgrp.DlvyInstGrp } -func (m *SettlInstructionsData) SetSettlDeliveryType(v int) { m.SettlDeliveryType = &v } -func (m *SettlInstructionsData) SetStandInstDbType(v int) { m.StandInstDbType = &v } -func (m *SettlInstructionsData) SetStandInstDbName(v string) { m.StandInstDbName = &v } -func (m *SettlInstructionsData) SetStandInstDbID(v string) { m.StandInstDbID = &v } -func (m *SettlInstructionsData) SetNoDlvyInst(v []NoDlvyInst) { m.NoDlvyInst = v } +func (m *SettlInstructionsData) SetSettlDeliveryType(v int) { m.SettlDeliveryType = &v } +func (m *SettlInstructionsData) SetStandInstDbType(v int) { m.StandInstDbType = &v } +func (m *SettlInstructionsData) SetStandInstDbName(v string) { m.StandInstDbName = &v } +func (m *SettlInstructionsData) SetStandInstDbID(v string) { m.StandInstDbID = &v } diff --git a/fix50/underlyinginstrument/UnderlyingInstrument.go b/fix50/underlyinginstrument/UnderlyingInstrument.go index 7d83acf41..35b195c38 100644 --- a/fix50/underlyinginstrument/UnderlyingInstrument.go +++ b/fix50/underlyinginstrument/UnderlyingInstrument.go @@ -1,37 +1,11 @@ package underlyinginstrument import ( - "github.com/quickfixgo/quickfix/fix50/undlyinstrumentptyssubgrp" + "github.com/quickfixgo/quickfix/fix50/underlyingstipulations" + "github.com/quickfixgo/quickfix/fix50/undlyinstrumentparties" + "github.com/quickfixgo/quickfix/fix50/undsecaltidgrp" ) -//NoUnderlyingSecurityAltID is a repeating group in UnderlyingInstrument -type NoUnderlyingSecurityAltID struct { - //UnderlyingSecurityAltID is a non-required field for NoUnderlyingSecurityAltID. - UnderlyingSecurityAltID *string `fix:"458"` - //UnderlyingSecurityAltIDSource is a non-required field for NoUnderlyingSecurityAltID. - UnderlyingSecurityAltIDSource *string `fix:"459"` -} - -//NoUnderlyingStips is a repeating group in UnderlyingInstrument -type NoUnderlyingStips struct { - //UnderlyingStipType is a non-required field for NoUnderlyingStips. - UnderlyingStipType *string `fix:"888"` - //UnderlyingStipValue is a non-required field for NoUnderlyingStips. - UnderlyingStipValue *string `fix:"889"` -} - -//NoUndlyInstrumentParties is a repeating group in UnderlyingInstrument -type NoUndlyInstrumentParties struct { - //UndlyInstrumentPartyID is a non-required field for NoUndlyInstrumentParties. - UndlyInstrumentPartyID *string `fix:"1059"` - //UndlyInstrumentPartyIDSource is a non-required field for NoUndlyInstrumentParties. - UndlyInstrumentPartyIDSource *string `fix:"1060"` - //UndlyInstrumentPartyRole is a non-required field for NoUndlyInstrumentParties. - UndlyInstrumentPartyRole *int `fix:"1061"` - //UndlyInstrumentPtysSubGrp Component - undlyinstrumentptyssubgrp.UndlyInstrumentPtysSubGrp -} - //UnderlyingInstrument is a fix50 Component type UnderlyingInstrument struct { //UnderlyingSymbol is a non-required field for UnderlyingInstrument. @@ -42,8 +16,8 @@ type UnderlyingInstrument struct { UnderlyingSecurityID *string `fix:"309"` //UnderlyingSecurityIDSource is a non-required field for UnderlyingInstrument. UnderlyingSecurityIDSource *string `fix:"305"` - //NoUnderlyingSecurityAltID is a non-required field for UnderlyingInstrument. - NoUnderlyingSecurityAltID []NoUnderlyingSecurityAltID `fix:"457,omitempty"` + //UndSecAltIDGrp Component + undsecaltidgrp.UndSecAltIDGrp //UnderlyingProduct is a non-required field for UnderlyingInstrument. UnderlyingProduct *int `fix:"462"` //UnderlyingCFICode is a non-required field for UnderlyingInstrument. @@ -124,8 +98,8 @@ type UnderlyingInstrument struct { UnderlyingCurrentValue *float64 `fix:"885"` //UnderlyingEndValue is a non-required field for UnderlyingInstrument. UnderlyingEndValue *float64 `fix:"886"` - //NoUnderlyingStips is a non-required field for UnderlyingInstrument. - NoUnderlyingStips []NoUnderlyingStips `fix:"887,omitempty"` + //UnderlyingStipulations Component + underlyingstipulations.UnderlyingStipulations //UnderlyingAllocationPercent is a non-required field for UnderlyingInstrument. UnderlyingAllocationPercent *float64 `fix:"972"` //UnderlyingSettlementType is a non-required field for UnderlyingInstrument. @@ -140,8 +114,8 @@ type UnderlyingInstrument struct { UnderlyingTimeUnit *string `fix:"1000"` //UnderlyingCapValue is a non-required field for UnderlyingInstrument. UnderlyingCapValue *float64 `fix:"1038"` - //NoUndlyInstrumentParties is a non-required field for UnderlyingInstrument. - NoUndlyInstrumentParties []NoUndlyInstrumentParties `fix:"1058,omitempty"` + //UndlyInstrumentParties Component + undlyinstrumentparties.UndlyInstrumentParties //UnderlyingSettlMethod is a non-required field for UnderlyingInstrument. UnderlyingSettlMethod *string `fix:"1039"` //UnderlyingAdjustedQuantity is a non-required field for UnderlyingInstrument. @@ -158,9 +132,6 @@ func (m *UnderlyingInstrument) SetUnderlyingSecurityID(v string) { m.UnderlyingS func (m *UnderlyingInstrument) SetUnderlyingSecurityIDSource(v string) { m.UnderlyingSecurityIDSource = &v } -func (m *UnderlyingInstrument) SetNoUnderlyingSecurityAltID(v []NoUnderlyingSecurityAltID) { - m.NoUnderlyingSecurityAltID = v -} func (m *UnderlyingInstrument) SetUnderlyingProduct(v int) { m.UnderlyingProduct = &v } func (m *UnderlyingInstrument) SetUnderlyingCFICode(v string) { m.UnderlyingCFICode = &v } func (m *UnderlyingInstrument) SetUnderlyingSecurityType(v string) { m.UnderlyingSecurityType = &v } @@ -209,17 +180,16 @@ func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDescLen(v int) { func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDesc(v string) { m.EncodedUnderlyingSecurityDesc = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } -func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } -func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } -func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } -func (m *UnderlyingInstrument) SetNoUnderlyingStips(v []NoUnderlyingStips) { m.NoUnderlyingStips = v } +func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } +func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } +func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } +func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } +func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } func (m *UnderlyingInstrument) SetUnderlyingAllocationPercent(v float64) { m.UnderlyingAllocationPercent = &v } @@ -229,10 +199,7 @@ func (m *UnderlyingInstrument) SetUnderlyingCashType(v string) { m.Underlyi func (m *UnderlyingInstrument) SetUnderlyingUnitOfMeasure(v string) { m.UnderlyingUnitOfMeasure = &v } func (m *UnderlyingInstrument) SetUnderlyingTimeUnit(v string) { m.UnderlyingTimeUnit = &v } func (m *UnderlyingInstrument) SetUnderlyingCapValue(v float64) { m.UnderlyingCapValue = &v } -func (m *UnderlyingInstrument) SetNoUndlyInstrumentParties(v []NoUndlyInstrumentParties) { - m.NoUndlyInstrumentParties = v -} -func (m *UnderlyingInstrument) SetUnderlyingSettlMethod(v string) { m.UnderlyingSettlMethod = &v } +func (m *UnderlyingInstrument) SetUnderlyingSettlMethod(v string) { m.UnderlyingSettlMethod = &v } func (m *UnderlyingInstrument) SetUnderlyingAdjustedQuantity(v float64) { m.UnderlyingAdjustedQuantity = &v } diff --git a/fix50sp1/basetradingrules/BaseTradingRules.go b/fix50sp1/basetradingrules/BaseTradingRules.go index 5e510d7a4..4437998c9 100644 --- a/fix50sp1/basetradingrules/BaseTradingRules.go +++ b/fix50sp1/basetradingrules/BaseTradingRules.go @@ -1,39 +1,19 @@ package basetradingrules -//NoTickRules is a repeating group in BaseTradingRules -type NoTickRules struct { - //StartTickPriceRange is a non-required field for NoTickRules. - StartTickPriceRange *float64 `fix:"1206"` - //EndTickPriceRange is a non-required field for NoTickRules. - EndTickPriceRange *float64 `fix:"1207"` - //TickIncrement is a non-required field for NoTickRules. - TickIncrement *float64 `fix:"1208"` - //TickRuleType is a non-required field for NoTickRules. - TickRuleType *int `fix:"1209"` -} - -//NoLotTypeRules is a repeating group in BaseTradingRules -type NoLotTypeRules struct { - //LotType is a non-required field for NoLotTypeRules. - LotType *string `fix:"1093"` - //MinLotSize is a non-required field for NoLotTypeRules. - MinLotSize *float64 `fix:"1231"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp1/lottyperules" + "github.com/quickfixgo/quickfix/fix50sp1/pricelimits" + "github.com/quickfixgo/quickfix/fix50sp1/tickrules" +) //BaseTradingRules is a fix50sp1 Component type BaseTradingRules struct { - //NoTickRules is a non-required field for BaseTradingRules. - NoTickRules []NoTickRules `fix:"1205,omitempty"` - //NoLotTypeRules is a non-required field for BaseTradingRules. - NoLotTypeRules []NoLotTypeRules `fix:"1234,omitempty"` - //PriceLimitType is a non-required field for BaseTradingRules. - PriceLimitType *int `fix:"1306"` - //LowLimitPrice is a non-required field for BaseTradingRules. - LowLimitPrice *float64 `fix:"1148"` - //HighLimitPrice is a non-required field for BaseTradingRules. - HighLimitPrice *float64 `fix:"1149"` - //TradingReferencePrice is a non-required field for BaseTradingRules. - TradingReferencePrice *float64 `fix:"1150"` + //TickRules Component + tickrules.TickRules + //LotTypeRules Component + lottyperules.LotTypeRules + //PriceLimits Component + pricelimits.PriceLimits //ExpirationCycle is a non-required field for BaseTradingRules. ExpirationCycle *int `fix:"827"` //MinTradeVol is a non-required field for BaseTradingRules. @@ -56,19 +36,13 @@ type BaseTradingRules struct { PriceType *int `fix:"423"` } -func (m *BaseTradingRules) SetNoTickRules(v []NoTickRules) { m.NoTickRules = v } -func (m *BaseTradingRules) SetNoLotTypeRules(v []NoLotTypeRules) { m.NoLotTypeRules = v } -func (m *BaseTradingRules) SetPriceLimitType(v int) { m.PriceLimitType = &v } -func (m *BaseTradingRules) SetLowLimitPrice(v float64) { m.LowLimitPrice = &v } -func (m *BaseTradingRules) SetHighLimitPrice(v float64) { m.HighLimitPrice = &v } -func (m *BaseTradingRules) SetTradingReferencePrice(v float64) { m.TradingReferencePrice = &v } -func (m *BaseTradingRules) SetExpirationCycle(v int) { m.ExpirationCycle = &v } -func (m *BaseTradingRules) SetMinTradeVol(v float64) { m.MinTradeVol = &v } -func (m *BaseTradingRules) SetMaxTradeVol(v float64) { m.MaxTradeVol = &v } -func (m *BaseTradingRules) SetMaxPriceVariation(v float64) { m.MaxPriceVariation = &v } -func (m *BaseTradingRules) SetImpliedMarketIndicator(v int) { m.ImpliedMarketIndicator = &v } -func (m *BaseTradingRules) SetTradingCurrency(v string) { m.TradingCurrency = &v } -func (m *BaseTradingRules) SetRoundLot(v float64) { m.RoundLot = &v } -func (m *BaseTradingRules) SetMultilegModel(v int) { m.MultilegModel = &v } -func (m *BaseTradingRules) SetMultilegPriceMethod(v int) { m.MultilegPriceMethod = &v } -func (m *BaseTradingRules) SetPriceType(v int) { m.PriceType = &v } +func (m *BaseTradingRules) SetExpirationCycle(v int) { m.ExpirationCycle = &v } +func (m *BaseTradingRules) SetMinTradeVol(v float64) { m.MinTradeVol = &v } +func (m *BaseTradingRules) SetMaxTradeVol(v float64) { m.MaxTradeVol = &v } +func (m *BaseTradingRules) SetMaxPriceVariation(v float64) { m.MaxPriceVariation = &v } +func (m *BaseTradingRules) SetImpliedMarketIndicator(v int) { m.ImpliedMarketIndicator = &v } +func (m *BaseTradingRules) SetTradingCurrency(v string) { m.TradingCurrency = &v } +func (m *BaseTradingRules) SetRoundLot(v float64) { m.RoundLot = &v } +func (m *BaseTradingRules) SetMultilegModel(v int) { m.MultilegModel = &v } +func (m *BaseTradingRules) SetMultilegPriceMethod(v int) { m.MultilegPriceMethod = &v } +func (m *BaseTradingRules) SetPriceType(v int) { m.PriceType = &v } diff --git a/fix50sp1/derivativeinstrument/DerivativeInstrument.go b/fix50sp1/derivativeinstrument/DerivativeInstrument.go index 4c615ff10..7cec467e5 100644 --- a/fix50sp1/derivativeinstrument/DerivativeInstrument.go +++ b/fix50sp1/derivativeinstrument/DerivativeInstrument.go @@ -1,44 +1,12 @@ package derivativeinstrument import ( - "github.com/quickfixgo/quickfix/fix50sp1/derivativeinstrumentpartysubidsgrp" - "time" + "github.com/quickfixgo/quickfix/fix50sp1/derivativeeventsgrp" + "github.com/quickfixgo/quickfix/fix50sp1/derivativeinstrumentparties" + "github.com/quickfixgo/quickfix/fix50sp1/derivativesecurityaltidgrp" + "github.com/quickfixgo/quickfix/fix50sp1/derivativesecurityxml" ) -//NoDerivativeSecurityAltID is a repeating group in DerivativeInstrument -type NoDerivativeSecurityAltID struct { - //DerivativeSecurityAltID is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltID *string `fix:"1219"` - //DerivativeSecurityAltIDSource is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltIDSource *string `fix:"1220"` -} - -//NoDerivativeEvents is a repeating group in DerivativeInstrument -type NoDerivativeEvents struct { - //DerivativeEventType is a non-required field for NoDerivativeEvents. - DerivativeEventType *int `fix:"1287"` - //DerivativeEventDate is a non-required field for NoDerivativeEvents. - DerivativeEventDate *string `fix:"1288"` - //DerivativeEventTime is a non-required field for NoDerivativeEvents. - DerivativeEventTime *time.Time `fix:"1289"` - //DerivativeEventPx is a non-required field for NoDerivativeEvents. - DerivativeEventPx *float64 `fix:"1290"` - //DerivativeEventText is a non-required field for NoDerivativeEvents. - DerivativeEventText *string `fix:"1291"` -} - -//NoDerivativeInstrumentParties is a repeating group in DerivativeInstrument -type NoDerivativeInstrumentParties struct { - //DerivativeInstrumentPartyID is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyID *string `fix:"1293"` - //DerivativeInstrumentPartyIDSource is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyIDSource *string `fix:"1294"` - //DerivativeInstrumentPartyRole is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyRole *int `fix:"1295"` - //DerivativeInstrumentPartySubIDsGrp Component - derivativeinstrumentpartysubidsgrp.DerivativeInstrumentPartySubIDsGrp -} - //DerivativeInstrument is a fix50sp1 Component type DerivativeInstrument struct { //DerivativeSymbol is a non-required field for DerivativeInstrument. @@ -49,8 +17,8 @@ type DerivativeInstrument struct { DerivativeSecurityID *string `fix:"1216"` //DerivativeSecurityIDSource is a non-required field for DerivativeInstrument. DerivativeSecurityIDSource *string `fix:"1217"` - //NoDerivativeSecurityAltID is a non-required field for DerivativeInstrument. - NoDerivativeSecurityAltID []NoDerivativeSecurityAltID `fix:"1218,omitempty"` + //DerivativeSecurityAltIDGrp Component + derivativesecurityaltidgrp.DerivativeSecurityAltIDGrp //DerivativeProduct is a non-required field for DerivativeInstrument. DerivativeProduct *int `fix:"1246"` //DerivativeProductComplex is a non-required field for DerivativeInstrument. @@ -137,10 +105,10 @@ type DerivativeInstrument struct { DerivativeEncodedSecurityDesc *string `fix:"1281"` //DerivativeContractSettlMonth is a non-required field for DerivativeInstrument. DerivativeContractSettlMonth *string `fix:"1285"` - //NoDerivativeEvents is a non-required field for DerivativeInstrument. - NoDerivativeEvents []NoDerivativeEvents `fix:"1286,omitempty"` - //NoDerivativeInstrumentParties is a non-required field for DerivativeInstrument. - NoDerivativeInstrumentParties []NoDerivativeInstrumentParties `fix:"1292,omitempty"` + //DerivativeEventsGrp Component + derivativeeventsgrp.DerivativeEventsGrp + //DerivativeInstrumentParties Component + derivativeinstrumentparties.DerivativeInstrumentParties //DerivativeSettlMethod is a non-required field for DerivativeInstrument. DerivativeSettlMethod *string `fix:"1317"` //DerivativePriceQuoteMethod is a non-required field for DerivativeInstrument. @@ -155,12 +123,8 @@ type DerivativeInstrument struct { DerivativeFloorPrice *float64 `fix:"1322"` //DerivativePutOrCall is a non-required field for DerivativeInstrument. DerivativePutOrCall *int `fix:"1323"` - //DerivativeSecurityXMLLen is a non-required field for DerivativeInstrument. - DerivativeSecurityXMLLen *int `fix:"1282"` - //DerivativeSecurityXML is a non-required field for DerivativeInstrument. - DerivativeSecurityXML *string `fix:"1283"` - //DerivativeSecurityXMLSchema is a non-required field for DerivativeInstrument. - DerivativeSecurityXMLSchema *string `fix:"1284"` + //DerivativeSecurityXML Component + derivativesecurityxml.DerivativeSecurityXML } func (m *DerivativeInstrument) SetDerivativeSymbol(v string) { m.DerivativeSymbol = &v } @@ -169,9 +133,6 @@ func (m *DerivativeInstrument) SetDerivativeSecurityID(v string) { m.DerivativeS func (m *DerivativeInstrument) SetDerivativeSecurityIDSource(v string) { m.DerivativeSecurityIDSource = &v } -func (m *DerivativeInstrument) SetNoDerivativeSecurityAltID(v []NoDerivativeSecurityAltID) { - m.NoDerivativeSecurityAltID = v -} func (m *DerivativeInstrument) SetDerivativeProduct(v int) { m.DerivativeProduct = &v } func (m *DerivativeInstrument) SetDerivativeProductComplex(v string) { m.DerivativeProductComplex = &v } func (m *DerivativeInstrument) SetDerivFlexProductEligibilityIndicator(v bool) { @@ -249,10 +210,6 @@ func (m *DerivativeInstrument) SetDerivativeEncodedSecurityDesc(v string) { func (m *DerivativeInstrument) SetDerivativeContractSettlMonth(v string) { m.DerivativeContractSettlMonth = &v } -func (m *DerivativeInstrument) SetNoDerivativeEvents(v []NoDerivativeEvents) { m.NoDerivativeEvents = v } -func (m *DerivativeInstrument) SetNoDerivativeInstrumentParties(v []NoDerivativeInstrumentParties) { - m.NoDerivativeInstrumentParties = v -} func (m *DerivativeInstrument) SetDerivativeSettlMethod(v string) { m.DerivativeSettlMethod = &v } func (m *DerivativeInstrument) SetDerivativePriceQuoteMethod(v string) { m.DerivativePriceQuoteMethod = &v @@ -264,8 +221,3 @@ func (m *DerivativeInstrument) SetDerivativeListMethod(v int) { m.Derivative func (m *DerivativeInstrument) SetDerivativeCapPrice(v float64) { m.DerivativeCapPrice = &v } func (m *DerivativeInstrument) SetDerivativeFloorPrice(v float64) { m.DerivativeFloorPrice = &v } func (m *DerivativeInstrument) SetDerivativePutOrCall(v int) { m.DerivativePutOrCall = &v } -func (m *DerivativeInstrument) SetDerivativeSecurityXMLLen(v int) { m.DerivativeSecurityXMLLen = &v } -func (m *DerivativeInstrument) SetDerivativeSecurityXML(v string) { m.DerivativeSecurityXML = &v } -func (m *DerivativeInstrument) SetDerivativeSecurityXMLSchema(v string) { - m.DerivativeSecurityXMLSchema = &v -} diff --git a/fix50sp1/derivativesecuritydefinition/DerivativeSecurityDefinition.go b/fix50sp1/derivativesecuritydefinition/DerivativeSecurityDefinition.go index a049c2b30..b45d347fb 100644 --- a/fix50sp1/derivativesecuritydefinition/DerivativeSecurityDefinition.go +++ b/fix50sp1/derivativesecuritydefinition/DerivativeSecurityDefinition.go @@ -1,353 +1,17 @@ package derivativesecuritydefinition import ( - "github.com/quickfixgo/quickfix/fix50sp1/derivativeinstrumentpartysubidsgrp" - "github.com/quickfixgo/quickfix/fix50sp1/securitytradingrules" - "github.com/quickfixgo/quickfix/fix50sp1/strikerules" - "time" + "github.com/quickfixgo/quickfix/fix50sp1/derivativeinstrument" + "github.com/quickfixgo/quickfix/fix50sp1/derivativeinstrumentattribute" + "github.com/quickfixgo/quickfix/fix50sp1/marketsegmentgrp" ) -//NoDerivativeSecurityAltID is a repeating group in DerivativeSecurityDefinition -type NoDerivativeSecurityAltID struct { - //DerivativeSecurityAltID is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltID *string `fix:"1219"` - //DerivativeSecurityAltIDSource is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltIDSource *string `fix:"1220"` -} - -//NoDerivativeEvents is a repeating group in DerivativeSecurityDefinition -type NoDerivativeEvents struct { - //DerivativeEventType is a non-required field for NoDerivativeEvents. - DerivativeEventType *int `fix:"1287"` - //DerivativeEventDate is a non-required field for NoDerivativeEvents. - DerivativeEventDate *string `fix:"1288"` - //DerivativeEventTime is a non-required field for NoDerivativeEvents. - DerivativeEventTime *time.Time `fix:"1289"` - //DerivativeEventPx is a non-required field for NoDerivativeEvents. - DerivativeEventPx *float64 `fix:"1290"` - //DerivativeEventText is a non-required field for NoDerivativeEvents. - DerivativeEventText *string `fix:"1291"` -} - -//NoDerivativeInstrumentParties is a repeating group in DerivativeSecurityDefinition -type NoDerivativeInstrumentParties struct { - //DerivativeInstrumentPartyID is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyID *string `fix:"1293"` - //DerivativeInstrumentPartyIDSource is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyIDSource *string `fix:"1294"` - //DerivativeInstrumentPartyRole is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyRole *int `fix:"1295"` - //DerivativeInstrumentPartySubIDsGrp Component - derivativeinstrumentpartysubidsgrp.DerivativeInstrumentPartySubIDsGrp -} - -//NoDerivativeInstrAttrib is a repeating group in DerivativeSecurityDefinition -type NoDerivativeInstrAttrib struct { - //DerivativeInstrAttribType is a non-required field for NoDerivativeInstrAttrib. - DerivativeInstrAttribType *int `fix:"1313"` - //DerivativeInstrAttribValue is a non-required field for NoDerivativeInstrAttrib. - DerivativeInstrAttribValue *string `fix:"1314"` -} - -//NoMarketSegments is a repeating group in DerivativeSecurityDefinition -type NoMarketSegments struct { - //MarketID is a non-required field for NoMarketSegments. - MarketID *string `fix:"1301"` - //MarketSegmentID is a non-required field for NoMarketSegments. - MarketSegmentID *string `fix:"1300"` - //SecurityTradingRules Component - securitytradingrules.SecurityTradingRules - //StrikeRules Component - strikerules.StrikeRules -} - //DerivativeSecurityDefinition is a fix50sp1 Component type DerivativeSecurityDefinition struct { - //DerivativeSymbol is a non-required field for DerivativeSecurityDefinition. - DerivativeSymbol *string `fix:"1214"` - //DerivativeSymbolSfx is a non-required field for DerivativeSecurityDefinition. - DerivativeSymbolSfx *string `fix:"1215"` - //DerivativeSecurityID is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityID *string `fix:"1216"` - //DerivativeSecurityIDSource is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityIDSource *string `fix:"1217"` - //NoDerivativeSecurityAltID is a non-required field for DerivativeSecurityDefinition. - NoDerivativeSecurityAltID []NoDerivativeSecurityAltID `fix:"1218,omitempty"` - //DerivativeProduct is a non-required field for DerivativeSecurityDefinition. - DerivativeProduct *int `fix:"1246"` - //DerivativeProductComplex is a non-required field for DerivativeSecurityDefinition. - DerivativeProductComplex *string `fix:"1228"` - //DerivFlexProductEligibilityIndicator is a non-required field for DerivativeSecurityDefinition. - DerivFlexProductEligibilityIndicator *bool `fix:"1243"` - //DerivativeSecurityGroup is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityGroup *string `fix:"1247"` - //DerivativeCFICode is a non-required field for DerivativeSecurityDefinition. - DerivativeCFICode *string `fix:"1248"` - //DerivativeSecurityType is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityType *string `fix:"1249"` - //DerivativeSecuritySubType is a non-required field for DerivativeSecurityDefinition. - DerivativeSecuritySubType *string `fix:"1250"` - //DerivativeMaturityMonthYear is a non-required field for DerivativeSecurityDefinition. - DerivativeMaturityMonthYear *string `fix:"1251"` - //DerivativeMaturityDate is a non-required field for DerivativeSecurityDefinition. - DerivativeMaturityDate *string `fix:"1252"` - //DerivativeMaturityTime is a non-required field for DerivativeSecurityDefinition. - DerivativeMaturityTime *string `fix:"1253"` - //DerivativeSettleOnOpenFlag is a non-required field for DerivativeSecurityDefinition. - DerivativeSettleOnOpenFlag *string `fix:"1254"` - //DerivativeInstrmtAssignmentMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeInstrmtAssignmentMethod *string `fix:"1255"` - //DerivativeSecurityStatus is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityStatus *string `fix:"1256"` - //DerivativeIssueDate is a non-required field for DerivativeSecurityDefinition. - DerivativeIssueDate *string `fix:"1276"` - //DerivativeInstrRegistry is a non-required field for DerivativeSecurityDefinition. - DerivativeInstrRegistry *string `fix:"1257"` - //DerivativeCountryOfIssue is a non-required field for DerivativeSecurityDefinition. - DerivativeCountryOfIssue *string `fix:"1258"` - //DerivativeStateOrProvinceOfIssue is a non-required field for DerivativeSecurityDefinition. - DerivativeStateOrProvinceOfIssue *string `fix:"1259"` - //DerivativeStrikePrice is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikePrice *float64 `fix:"1261"` - //DerivativeLocaleOfIssue is a non-required field for DerivativeSecurityDefinition. - DerivativeLocaleOfIssue *string `fix:"1260"` - //DerivativeStrikeCurrency is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikeCurrency *string `fix:"1262"` - //DerivativeStrikeMultiplier is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikeMultiplier *float64 `fix:"1263"` - //DerivativeStrikeValue is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikeValue *float64 `fix:"1264"` - //DerivativeOptAttribute is a non-required field for DerivativeSecurityDefinition. - DerivativeOptAttribute *string `fix:"1265"` - //DerivativeContractMultiplier is a non-required field for DerivativeSecurityDefinition. - DerivativeContractMultiplier *float64 `fix:"1266"` - //DerivativeMinPriceIncrement is a non-required field for DerivativeSecurityDefinition. - DerivativeMinPriceIncrement *float64 `fix:"1267"` - //DerivativeMinPriceIncrementAmount is a non-required field for DerivativeSecurityDefinition. - DerivativeMinPriceIncrementAmount *float64 `fix:"1268"` - //DerivativeUnitOfMeasure is a non-required field for DerivativeSecurityDefinition. - DerivativeUnitOfMeasure *string `fix:"1269"` - //DerivativeUnitOfMeasureQty is a non-required field for DerivativeSecurityDefinition. - DerivativeUnitOfMeasureQty *float64 `fix:"1270"` - //DerivativePriceUnitOfMeasure is a non-required field for DerivativeSecurityDefinition. - DerivativePriceUnitOfMeasure *string `fix:"1315"` - //DerivativePriceUnitOfMeasureQty is a non-required field for DerivativeSecurityDefinition. - DerivativePriceUnitOfMeasureQty *float64 `fix:"1316"` - //DerivativeExerciseStyle is a non-required field for DerivativeSecurityDefinition. - DerivativeExerciseStyle *string `fix:"1299"` - //DerivativeOptPayAmount is a non-required field for DerivativeSecurityDefinition. - DerivativeOptPayAmount *float64 `fix:"1225"` - //DerivativeTimeUnit is a non-required field for DerivativeSecurityDefinition. - DerivativeTimeUnit *string `fix:"1271"` - //DerivativeSecurityExchange is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityExchange *string `fix:"1272"` - //DerivativePositionLimit is a non-required field for DerivativeSecurityDefinition. - DerivativePositionLimit *int `fix:"1273"` - //DerivativeNTPositionLimit is a non-required field for DerivativeSecurityDefinition. - DerivativeNTPositionLimit *int `fix:"1274"` - //DerivativeIssuer is a non-required field for DerivativeSecurityDefinition. - DerivativeIssuer *string `fix:"1275"` - //DerivativeEncodedIssuerLen is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedIssuerLen *int `fix:"1277"` - //DerivativeEncodedIssuer is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedIssuer *string `fix:"1278"` - //DerivativeSecurityDesc is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityDesc *string `fix:"1279"` - //DerivativeEncodedSecurityDescLen is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedSecurityDescLen *int `fix:"1280"` - //DerivativeEncodedSecurityDesc is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedSecurityDesc *string `fix:"1281"` - //DerivativeContractSettlMonth is a non-required field for DerivativeSecurityDefinition. - DerivativeContractSettlMonth *string `fix:"1285"` - //NoDerivativeEvents is a non-required field for DerivativeSecurityDefinition. - NoDerivativeEvents []NoDerivativeEvents `fix:"1286,omitempty"` - //NoDerivativeInstrumentParties is a non-required field for DerivativeSecurityDefinition. - NoDerivativeInstrumentParties []NoDerivativeInstrumentParties `fix:"1292,omitempty"` - //DerivativeSettlMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeSettlMethod *string `fix:"1317"` - //DerivativePriceQuoteMethod is a non-required field for DerivativeSecurityDefinition. - DerivativePriceQuoteMethod *string `fix:"1318"` - //DerivativeFuturesValuationMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeFuturesValuationMethod *string `fix:"1319"` - //DerivativeListMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeListMethod *int `fix:"1320"` - //DerivativeCapPrice is a non-required field for DerivativeSecurityDefinition. - DerivativeCapPrice *float64 `fix:"1321"` - //DerivativeFloorPrice is a non-required field for DerivativeSecurityDefinition. - DerivativeFloorPrice *float64 `fix:"1322"` - //DerivativePutOrCall is a non-required field for DerivativeSecurityDefinition. - DerivativePutOrCall *int `fix:"1323"` - //DerivativeSecurityXMLLen is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityXMLLen *int `fix:"1282"` - //DerivativeSecurityXML is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityXML *string `fix:"1283"` - //DerivativeSecurityXMLSchema is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityXMLSchema *string `fix:"1284"` - //NoDerivativeInstrAttrib is a non-required field for DerivativeSecurityDefinition. - NoDerivativeInstrAttrib []NoDerivativeInstrAttrib `fix:"1311,omitempty"` - //NoMarketSegments is a non-required field for DerivativeSecurityDefinition. - NoMarketSegments []NoMarketSegments `fix:"1310,omitempty"` -} - -func (m *DerivativeSecurityDefinition) SetDerivativeSymbol(v string) { m.DerivativeSymbol = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSymbolSfx(v string) { m.DerivativeSymbolSfx = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityID(v string) { m.DerivativeSecurityID = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityIDSource(v string) { - m.DerivativeSecurityIDSource = &v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeSecurityAltID(v []NoDerivativeSecurityAltID) { - m.NoDerivativeSecurityAltID = v -} -func (m *DerivativeSecurityDefinition) SetDerivativeProduct(v int) { m.DerivativeProduct = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeProductComplex(v string) { - m.DerivativeProductComplex = &v -} -func (m *DerivativeSecurityDefinition) SetDerivFlexProductEligibilityIndicator(v bool) { - m.DerivFlexProductEligibilityIndicator = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityGroup(v string) { - m.DerivativeSecurityGroup = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeCFICode(v string) { m.DerivativeCFICode = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityType(v string) { - m.DerivativeSecurityType = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecuritySubType(v string) { - m.DerivativeSecuritySubType = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMaturityMonthYear(v string) { - m.DerivativeMaturityMonthYear = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMaturityDate(v string) { - m.DerivativeMaturityDate = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMaturityTime(v string) { - m.DerivativeMaturityTime = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSettleOnOpenFlag(v string) { - m.DerivativeSettleOnOpenFlag = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeInstrmtAssignmentMethod(v string) { - m.DerivativeInstrmtAssignmentMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityStatus(v string) { - m.DerivativeSecurityStatus = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeIssueDate(v string) { m.DerivativeIssueDate = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeInstrRegistry(v string) { - m.DerivativeInstrRegistry = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeCountryOfIssue(v string) { - m.DerivativeCountryOfIssue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStateOrProvinceOfIssue(v string) { - m.DerivativeStateOrProvinceOfIssue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikePrice(v float64) { - m.DerivativeStrikePrice = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeLocaleOfIssue(v string) { - m.DerivativeLocaleOfIssue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikeCurrency(v string) { - m.DerivativeStrikeCurrency = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikeMultiplier(v float64) { - m.DerivativeStrikeMultiplier = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikeValue(v float64) { - m.DerivativeStrikeValue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeOptAttribute(v string) { - m.DerivativeOptAttribute = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeContractMultiplier(v float64) { - m.DerivativeContractMultiplier = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMinPriceIncrement(v float64) { - m.DerivativeMinPriceIncrement = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMinPriceIncrementAmount(v float64) { - m.DerivativeMinPriceIncrementAmount = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeUnitOfMeasure(v string) { - m.DerivativeUnitOfMeasure = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeUnitOfMeasureQty(v float64) { - m.DerivativeUnitOfMeasureQty = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePriceUnitOfMeasure(v string) { - m.DerivativePriceUnitOfMeasure = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePriceUnitOfMeasureQty(v float64) { - m.DerivativePriceUnitOfMeasureQty = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeExerciseStyle(v string) { - m.DerivativeExerciseStyle = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeOptPayAmount(v float64) { - m.DerivativeOptPayAmount = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeTimeUnit(v string) { m.DerivativeTimeUnit = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityExchange(v string) { - m.DerivativeSecurityExchange = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePositionLimit(v int) { - m.DerivativePositionLimit = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeNTPositionLimit(v int) { - m.DerivativeNTPositionLimit = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeIssuer(v string) { m.DerivativeIssuer = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedIssuerLen(v int) { - m.DerivativeEncodedIssuerLen = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedIssuer(v string) { - m.DerivativeEncodedIssuer = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityDesc(v string) { - m.DerivativeSecurityDesc = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedSecurityDescLen(v int) { - m.DerivativeEncodedSecurityDescLen = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedSecurityDesc(v string) { - m.DerivativeEncodedSecurityDesc = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeContractSettlMonth(v string) { - m.DerivativeContractSettlMonth = &v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeEvents(v []NoDerivativeEvents) { - m.NoDerivativeEvents = v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeInstrumentParties(v []NoDerivativeInstrumentParties) { - m.NoDerivativeInstrumentParties = v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSettlMethod(v string) { - m.DerivativeSettlMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePriceQuoteMethod(v string) { - m.DerivativePriceQuoteMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeFuturesValuationMethod(v string) { - m.DerivativeFuturesValuationMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeListMethod(v int) { m.DerivativeListMethod = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeCapPrice(v float64) { m.DerivativeCapPrice = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeFloorPrice(v float64) { m.DerivativeFloorPrice = &v } -func (m *DerivativeSecurityDefinition) SetDerivativePutOrCall(v int) { m.DerivativePutOrCall = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityXMLLen(v int) { - m.DerivativeSecurityXMLLen = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityXML(v string) { - m.DerivativeSecurityXML = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityXMLSchema(v string) { - m.DerivativeSecurityXMLSchema = &v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeInstrAttrib(v []NoDerivativeInstrAttrib) { - m.NoDerivativeInstrAttrib = v -} -func (m *DerivativeSecurityDefinition) SetNoMarketSegments(v []NoMarketSegments) { - m.NoMarketSegments = v + //DerivativeInstrument Component + derivativeinstrument.DerivativeInstrument + //DerivativeInstrumentAttribute Component + derivativeinstrumentattribute.DerivativeInstrumentAttribute + //MarketSegmentGrp Component + marketsegmentgrp.MarketSegmentGrp } diff --git a/fix50sp1/instrument/Instrument.go b/fix50sp1/instrument/Instrument.go index d551a6b13..7c14d11aa 100644 --- a/fix50sp1/instrument/Instrument.go +++ b/fix50sp1/instrument/Instrument.go @@ -1,44 +1,12 @@ package instrument import ( - "github.com/quickfixgo/quickfix/fix50sp1/instrumentptyssubgrp" - "time" + "github.com/quickfixgo/quickfix/fix50sp1/evntgrp" + "github.com/quickfixgo/quickfix/fix50sp1/instrumentparties" + "github.com/quickfixgo/quickfix/fix50sp1/secaltidgrp" + "github.com/quickfixgo/quickfix/fix50sp1/securityxml" ) -//NoSecurityAltID is a repeating group in Instrument -type NoSecurityAltID struct { - //SecurityAltID is a non-required field for NoSecurityAltID. - SecurityAltID *string `fix:"455"` - //SecurityAltIDSource is a non-required field for NoSecurityAltID. - SecurityAltIDSource *string `fix:"456"` -} - -//NoEvents is a repeating group in Instrument -type NoEvents struct { - //EventType is a non-required field for NoEvents. - EventType *int `fix:"865"` - //EventDate is a non-required field for NoEvents. - EventDate *string `fix:"866"` - //EventPx is a non-required field for NoEvents. - EventPx *float64 `fix:"867"` - //EventText is a non-required field for NoEvents. - EventText *string `fix:"868"` - //EventTime is a non-required field for NoEvents. - EventTime *time.Time `fix:"1145"` -} - -//NoInstrumentParties is a repeating group in Instrument -type NoInstrumentParties struct { - //InstrumentPartyID is a non-required field for NoInstrumentParties. - InstrumentPartyID *string `fix:"1019"` - //InstrumentPartyIDSource is a non-required field for NoInstrumentParties. - InstrumentPartyIDSource *string `fix:"1050"` - //InstrumentPartyRole is a non-required field for NoInstrumentParties. - InstrumentPartyRole *int `fix:"1051"` - //InstrumentPtysSubGrp Component - instrumentptyssubgrp.InstrumentPtysSubGrp -} - //Instrument is a fix50sp1 Component type Instrument struct { //Symbol is a non-required field for Instrument. @@ -49,8 +17,8 @@ type Instrument struct { SecurityID *string `fix:"48"` //SecurityIDSource is a non-required field for Instrument. SecurityIDSource *string `fix:"22"` - //NoSecurityAltID is a non-required field for Instrument. - NoSecurityAltID []NoSecurityAltID `fix:"454,omitempty"` + //SecAltIDGrp Component + secaltidgrp.SecAltIDGrp //Product is a non-required field for Instrument. Product *int `fix:"460"` //CFICode is a non-required field for Instrument. @@ -119,8 +87,8 @@ type Instrument struct { CPProgram *int `fix:"875"` //CPRegType is a non-required field for Instrument. CPRegType *string `fix:"876"` - //NoEvents is a non-required field for Instrument. - NoEvents []NoEvents `fix:"864,omitempty"` + //EvntGrp Component + evntgrp.EvntGrp //DatedDate is a non-required field for Instrument. DatedDate *string `fix:"873"` //InterestAccrualDate is a non-required field for Instrument. @@ -141,8 +109,8 @@ type Instrument struct { PositionLimit *int `fix:"970"` //NTPositionLimit is a non-required field for Instrument. NTPositionLimit *int `fix:"971"` - //NoInstrumentParties is a non-required field for Instrument. - NoInstrumentParties []NoInstrumentParties `fix:"1018,omitempty"` + //InstrumentParties Component + instrumentparties.InstrumentParties //UnitOfMeasure is a non-required field for Instrument. UnitOfMeasure *string `fix:"996"` //TimeUnit is a non-required field for Instrument. @@ -155,12 +123,8 @@ type Instrument struct { MinPriceIncrementAmount *float64 `fix:"1146"` //UnitOfMeasureQty is a non-required field for Instrument. UnitOfMeasureQty *float64 `fix:"1147"` - //SecurityXMLLen is a non-required field for Instrument. - SecurityXMLLen *int `fix:"1184"` - //SecurityXML is a non-required field for Instrument. - SecurityXML *string `fix:"1185"` - //SecurityXMLSchema is a non-required field for Instrument. - SecurityXMLSchema *string `fix:"1186"` + //SecurityXML Component + securityxml.SecurityXML //ProductComplex is a non-required field for Instrument. ProductComplex *string `fix:"1227"` //PriceUnitOfMeasure is a non-required field for Instrument. @@ -191,78 +155,72 @@ type Instrument struct { FuturesValuationMethod *string `fix:"1197"` } -func (m *Instrument) SetSymbol(v string) { m.Symbol = &v } -func (m *Instrument) SetSymbolSfx(v string) { m.SymbolSfx = &v } -func (m *Instrument) SetSecurityID(v string) { m.SecurityID = &v } -func (m *Instrument) SetSecurityIDSource(v string) { m.SecurityIDSource = &v } -func (m *Instrument) SetNoSecurityAltID(v []NoSecurityAltID) { m.NoSecurityAltID = v } -func (m *Instrument) SetProduct(v int) { m.Product = &v } -func (m *Instrument) SetCFICode(v string) { m.CFICode = &v } -func (m *Instrument) SetSecurityType(v string) { m.SecurityType = &v } -func (m *Instrument) SetSecuritySubType(v string) { m.SecuritySubType = &v } -func (m *Instrument) SetMaturityMonthYear(v string) { m.MaturityMonthYear = &v } -func (m *Instrument) SetMaturityDate(v string) { m.MaturityDate = &v } -func (m *Instrument) SetCouponPaymentDate(v string) { m.CouponPaymentDate = &v } -func (m *Instrument) SetIssueDate(v string) { m.IssueDate = &v } -func (m *Instrument) SetRepoCollateralSecurityType(v int) { m.RepoCollateralSecurityType = &v } -func (m *Instrument) SetRepurchaseTerm(v int) { m.RepurchaseTerm = &v } -func (m *Instrument) SetRepurchaseRate(v float64) { m.RepurchaseRate = &v } -func (m *Instrument) SetFactor(v float64) { m.Factor = &v } -func (m *Instrument) SetCreditRating(v string) { m.CreditRating = &v } -func (m *Instrument) SetInstrRegistry(v string) { m.InstrRegistry = &v } -func (m *Instrument) SetCountryOfIssue(v string) { m.CountryOfIssue = &v } -func (m *Instrument) SetStateOrProvinceOfIssue(v string) { m.StateOrProvinceOfIssue = &v } -func (m *Instrument) SetLocaleOfIssue(v string) { m.LocaleOfIssue = &v } -func (m *Instrument) SetRedemptionDate(v string) { m.RedemptionDate = &v } -func (m *Instrument) SetStrikePrice(v float64) { m.StrikePrice = &v } -func (m *Instrument) SetStrikeCurrency(v string) { m.StrikeCurrency = &v } -func (m *Instrument) SetOptAttribute(v string) { m.OptAttribute = &v } -func (m *Instrument) SetContractMultiplier(v float64) { m.ContractMultiplier = &v } -func (m *Instrument) SetCouponRate(v float64) { m.CouponRate = &v } -func (m *Instrument) SetSecurityExchange(v string) { m.SecurityExchange = &v } -func (m *Instrument) SetIssuer(v string) { m.Issuer = &v } -func (m *Instrument) SetEncodedIssuerLen(v int) { m.EncodedIssuerLen = &v } -func (m *Instrument) SetEncodedIssuer(v string) { m.EncodedIssuer = &v } -func (m *Instrument) SetSecurityDesc(v string) { m.SecurityDesc = &v } -func (m *Instrument) SetEncodedSecurityDescLen(v int) { m.EncodedSecurityDescLen = &v } -func (m *Instrument) SetEncodedSecurityDesc(v string) { m.EncodedSecurityDesc = &v } -func (m *Instrument) SetPool(v string) { m.Pool = &v } -func (m *Instrument) SetContractSettlMonth(v string) { m.ContractSettlMonth = &v } -func (m *Instrument) SetCPProgram(v int) { m.CPProgram = &v } -func (m *Instrument) SetCPRegType(v string) { m.CPRegType = &v } -func (m *Instrument) SetNoEvents(v []NoEvents) { m.NoEvents = v } -func (m *Instrument) SetDatedDate(v string) { m.DatedDate = &v } -func (m *Instrument) SetInterestAccrualDate(v string) { m.InterestAccrualDate = &v } -func (m *Instrument) SetSecurityStatus(v string) { m.SecurityStatus = &v } -func (m *Instrument) SetSettleOnOpenFlag(v string) { m.SettleOnOpenFlag = &v } -func (m *Instrument) SetInstrmtAssignmentMethod(v string) { m.InstrmtAssignmentMethod = &v } -func (m *Instrument) SetStrikeMultiplier(v float64) { m.StrikeMultiplier = &v } -func (m *Instrument) SetStrikeValue(v float64) { m.StrikeValue = &v } -func (m *Instrument) SetMinPriceIncrement(v float64) { m.MinPriceIncrement = &v } -func (m *Instrument) SetPositionLimit(v int) { m.PositionLimit = &v } -func (m *Instrument) SetNTPositionLimit(v int) { m.NTPositionLimit = &v } -func (m *Instrument) SetNoInstrumentParties(v []NoInstrumentParties) { m.NoInstrumentParties = v } -func (m *Instrument) SetUnitOfMeasure(v string) { m.UnitOfMeasure = &v } -func (m *Instrument) SetTimeUnit(v string) { m.TimeUnit = &v } -func (m *Instrument) SetMaturityTime(v string) { m.MaturityTime = &v } -func (m *Instrument) SetSecurityGroup(v string) { m.SecurityGroup = &v } -func (m *Instrument) SetMinPriceIncrementAmount(v float64) { m.MinPriceIncrementAmount = &v } -func (m *Instrument) SetUnitOfMeasureQty(v float64) { m.UnitOfMeasureQty = &v } -func (m *Instrument) SetSecurityXMLLen(v int) { m.SecurityXMLLen = &v } -func (m *Instrument) SetSecurityXML(v string) { m.SecurityXML = &v } -func (m *Instrument) SetSecurityXMLSchema(v string) { m.SecurityXMLSchema = &v } -func (m *Instrument) SetProductComplex(v string) { m.ProductComplex = &v } -func (m *Instrument) SetPriceUnitOfMeasure(v string) { m.PriceUnitOfMeasure = &v } -func (m *Instrument) SetPriceUnitOfMeasureQty(v float64) { m.PriceUnitOfMeasureQty = &v } -func (m *Instrument) SetSettlMethod(v string) { m.SettlMethod = &v } -func (m *Instrument) SetExerciseStyle(v int) { m.ExerciseStyle = &v } -func (m *Instrument) SetOptPayAmount(v float64) { m.OptPayAmount = &v } -func (m *Instrument) SetPriceQuoteMethod(v string) { m.PriceQuoteMethod = &v } -func (m *Instrument) SetListMethod(v int) { m.ListMethod = &v } -func (m *Instrument) SetCapPrice(v float64) { m.CapPrice = &v } -func (m *Instrument) SetFloorPrice(v float64) { m.FloorPrice = &v } -func (m *Instrument) SetPutOrCall(v int) { m.PutOrCall = &v } -func (m *Instrument) SetFlexibleIndicator(v bool) { m.FlexibleIndicator = &v } +func (m *Instrument) SetSymbol(v string) { m.Symbol = &v } +func (m *Instrument) SetSymbolSfx(v string) { m.SymbolSfx = &v } +func (m *Instrument) SetSecurityID(v string) { m.SecurityID = &v } +func (m *Instrument) SetSecurityIDSource(v string) { m.SecurityIDSource = &v } +func (m *Instrument) SetProduct(v int) { m.Product = &v } +func (m *Instrument) SetCFICode(v string) { m.CFICode = &v } +func (m *Instrument) SetSecurityType(v string) { m.SecurityType = &v } +func (m *Instrument) SetSecuritySubType(v string) { m.SecuritySubType = &v } +func (m *Instrument) SetMaturityMonthYear(v string) { m.MaturityMonthYear = &v } +func (m *Instrument) SetMaturityDate(v string) { m.MaturityDate = &v } +func (m *Instrument) SetCouponPaymentDate(v string) { m.CouponPaymentDate = &v } +func (m *Instrument) SetIssueDate(v string) { m.IssueDate = &v } +func (m *Instrument) SetRepoCollateralSecurityType(v int) { m.RepoCollateralSecurityType = &v } +func (m *Instrument) SetRepurchaseTerm(v int) { m.RepurchaseTerm = &v } +func (m *Instrument) SetRepurchaseRate(v float64) { m.RepurchaseRate = &v } +func (m *Instrument) SetFactor(v float64) { m.Factor = &v } +func (m *Instrument) SetCreditRating(v string) { m.CreditRating = &v } +func (m *Instrument) SetInstrRegistry(v string) { m.InstrRegistry = &v } +func (m *Instrument) SetCountryOfIssue(v string) { m.CountryOfIssue = &v } +func (m *Instrument) SetStateOrProvinceOfIssue(v string) { m.StateOrProvinceOfIssue = &v } +func (m *Instrument) SetLocaleOfIssue(v string) { m.LocaleOfIssue = &v } +func (m *Instrument) SetRedemptionDate(v string) { m.RedemptionDate = &v } +func (m *Instrument) SetStrikePrice(v float64) { m.StrikePrice = &v } +func (m *Instrument) SetStrikeCurrency(v string) { m.StrikeCurrency = &v } +func (m *Instrument) SetOptAttribute(v string) { m.OptAttribute = &v } +func (m *Instrument) SetContractMultiplier(v float64) { m.ContractMultiplier = &v } +func (m *Instrument) SetCouponRate(v float64) { m.CouponRate = &v } +func (m *Instrument) SetSecurityExchange(v string) { m.SecurityExchange = &v } +func (m *Instrument) SetIssuer(v string) { m.Issuer = &v } +func (m *Instrument) SetEncodedIssuerLen(v int) { m.EncodedIssuerLen = &v } +func (m *Instrument) SetEncodedIssuer(v string) { m.EncodedIssuer = &v } +func (m *Instrument) SetSecurityDesc(v string) { m.SecurityDesc = &v } +func (m *Instrument) SetEncodedSecurityDescLen(v int) { m.EncodedSecurityDescLen = &v } +func (m *Instrument) SetEncodedSecurityDesc(v string) { m.EncodedSecurityDesc = &v } +func (m *Instrument) SetPool(v string) { m.Pool = &v } +func (m *Instrument) SetContractSettlMonth(v string) { m.ContractSettlMonth = &v } +func (m *Instrument) SetCPProgram(v int) { m.CPProgram = &v } +func (m *Instrument) SetCPRegType(v string) { m.CPRegType = &v } +func (m *Instrument) SetDatedDate(v string) { m.DatedDate = &v } +func (m *Instrument) SetInterestAccrualDate(v string) { m.InterestAccrualDate = &v } +func (m *Instrument) SetSecurityStatus(v string) { m.SecurityStatus = &v } +func (m *Instrument) SetSettleOnOpenFlag(v string) { m.SettleOnOpenFlag = &v } +func (m *Instrument) SetInstrmtAssignmentMethod(v string) { m.InstrmtAssignmentMethod = &v } +func (m *Instrument) SetStrikeMultiplier(v float64) { m.StrikeMultiplier = &v } +func (m *Instrument) SetStrikeValue(v float64) { m.StrikeValue = &v } +func (m *Instrument) SetMinPriceIncrement(v float64) { m.MinPriceIncrement = &v } +func (m *Instrument) SetPositionLimit(v int) { m.PositionLimit = &v } +func (m *Instrument) SetNTPositionLimit(v int) { m.NTPositionLimit = &v } +func (m *Instrument) SetUnitOfMeasure(v string) { m.UnitOfMeasure = &v } +func (m *Instrument) SetTimeUnit(v string) { m.TimeUnit = &v } +func (m *Instrument) SetMaturityTime(v string) { m.MaturityTime = &v } +func (m *Instrument) SetSecurityGroup(v string) { m.SecurityGroup = &v } +func (m *Instrument) SetMinPriceIncrementAmount(v float64) { m.MinPriceIncrementAmount = &v } +func (m *Instrument) SetUnitOfMeasureQty(v float64) { m.UnitOfMeasureQty = &v } +func (m *Instrument) SetProductComplex(v string) { m.ProductComplex = &v } +func (m *Instrument) SetPriceUnitOfMeasure(v string) { m.PriceUnitOfMeasure = &v } +func (m *Instrument) SetPriceUnitOfMeasureQty(v float64) { m.PriceUnitOfMeasureQty = &v } +func (m *Instrument) SetSettlMethod(v string) { m.SettlMethod = &v } +func (m *Instrument) SetExerciseStyle(v int) { m.ExerciseStyle = &v } +func (m *Instrument) SetOptPayAmount(v float64) { m.OptPayAmount = &v } +func (m *Instrument) SetPriceQuoteMethod(v string) { m.PriceQuoteMethod = &v } +func (m *Instrument) SetListMethod(v int) { m.ListMethod = &v } +func (m *Instrument) SetCapPrice(v float64) { m.CapPrice = &v } +func (m *Instrument) SetFloorPrice(v float64) { m.FloorPrice = &v } +func (m *Instrument) SetPutOrCall(v int) { m.PutOrCall = &v } +func (m *Instrument) SetFlexibleIndicator(v bool) { m.FlexibleIndicator = &v } func (m *Instrument) SetFlexProductEligibilityIndicator(v bool) { m.FlexProductEligibilityIndicator = &v } diff --git a/fix50sp1/instrumentextension/InstrumentExtension.go b/fix50sp1/instrumentextension/InstrumentExtension.go index f1dbd4776..31155ac47 100644 --- a/fix50sp1/instrumentextension/InstrumentExtension.go +++ b/fix50sp1/instrumentextension/InstrumentExtension.go @@ -1,12 +1,8 @@ package instrumentextension -//NoInstrAttrib is a repeating group in InstrumentExtension -type NoInstrAttrib struct { - //InstrAttribType is a non-required field for NoInstrAttrib. - InstrAttribType *int `fix:"871"` - //InstrAttribValue is a non-required field for NoInstrAttrib. - InstrAttribValue *string `fix:"872"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp1/attrbgrp" +) //InstrumentExtension is a fix50sp1 Component type InstrumentExtension struct { @@ -14,10 +10,9 @@ type InstrumentExtension struct { DeliveryForm *int `fix:"668"` //PctAtRisk is a non-required field for InstrumentExtension. PctAtRisk *float64 `fix:"869"` - //NoInstrAttrib is a non-required field for InstrumentExtension. - NoInstrAttrib []NoInstrAttrib `fix:"870,omitempty"` + //AttrbGrp Component + attrbgrp.AttrbGrp } -func (m *InstrumentExtension) SetDeliveryForm(v int) { m.DeliveryForm = &v } -func (m *InstrumentExtension) SetPctAtRisk(v float64) { m.PctAtRisk = &v } -func (m *InstrumentExtension) SetNoInstrAttrib(v []NoInstrAttrib) { m.NoInstrAttrib = v } +func (m *InstrumentExtension) SetDeliveryForm(v int) { m.DeliveryForm = &v } +func (m *InstrumentExtension) SetPctAtRisk(v float64) { m.PctAtRisk = &v } diff --git a/fix50sp1/instrumentleg/InstrumentLeg.go b/fix50sp1/instrumentleg/InstrumentLeg.go index 089b7889e..6f5e58cae 100644 --- a/fix50sp1/instrumentleg/InstrumentLeg.go +++ b/fix50sp1/instrumentleg/InstrumentLeg.go @@ -1,12 +1,8 @@ package instrumentleg -//NoLegSecurityAltID is a repeating group in InstrumentLeg -type NoLegSecurityAltID struct { - //LegSecurityAltID is a non-required field for NoLegSecurityAltID. - LegSecurityAltID *string `fix:"605"` - //LegSecurityAltIDSource is a non-required field for NoLegSecurityAltID. - LegSecurityAltIDSource *string `fix:"606"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp1/legsecaltidgrp" +) //InstrumentLeg is a fix50sp1 Component type InstrumentLeg struct { @@ -18,8 +14,8 @@ type InstrumentLeg struct { LegSecurityID *string `fix:"602"` //LegSecurityIDSource is a non-required field for InstrumentLeg. LegSecurityIDSource *string `fix:"603"` - //NoLegSecurityAltID is a non-required field for InstrumentLeg. - NoLegSecurityAltID []NoLegSecurityAltID `fix:"604,omitempty"` + //LegSecAltIDGrp Component + legsecaltidgrp.LegSecAltIDGrp //LegProduct is a non-required field for InstrumentLeg. LegProduct *int `fix:"607"` //LegCFICode is a non-required field for InstrumentLeg. @@ -116,55 +112,54 @@ type InstrumentLeg struct { LegPriceUnitOfMeasureQty *float64 `fix:"1422"` } -func (m *InstrumentLeg) SetLegSymbol(v string) { m.LegSymbol = &v } -func (m *InstrumentLeg) SetLegSymbolSfx(v string) { m.LegSymbolSfx = &v } -func (m *InstrumentLeg) SetLegSecurityID(v string) { m.LegSecurityID = &v } -func (m *InstrumentLeg) SetLegSecurityIDSource(v string) { m.LegSecurityIDSource = &v } -func (m *InstrumentLeg) SetNoLegSecurityAltID(v []NoLegSecurityAltID) { m.NoLegSecurityAltID = v } -func (m *InstrumentLeg) SetLegProduct(v int) { m.LegProduct = &v } -func (m *InstrumentLeg) SetLegCFICode(v string) { m.LegCFICode = &v } -func (m *InstrumentLeg) SetLegSecurityType(v string) { m.LegSecurityType = &v } -func (m *InstrumentLeg) SetLegSecuritySubType(v string) { m.LegSecuritySubType = &v } -func (m *InstrumentLeg) SetLegMaturityMonthYear(v string) { m.LegMaturityMonthYear = &v } -func (m *InstrumentLeg) SetLegMaturityDate(v string) { m.LegMaturityDate = &v } -func (m *InstrumentLeg) SetLegCouponPaymentDate(v string) { m.LegCouponPaymentDate = &v } -func (m *InstrumentLeg) SetLegIssueDate(v string) { m.LegIssueDate = &v } -func (m *InstrumentLeg) SetLegRepoCollateralSecurityType(v int) { m.LegRepoCollateralSecurityType = &v } -func (m *InstrumentLeg) SetLegRepurchaseTerm(v int) { m.LegRepurchaseTerm = &v } -func (m *InstrumentLeg) SetLegRepurchaseRate(v float64) { m.LegRepurchaseRate = &v } -func (m *InstrumentLeg) SetLegFactor(v float64) { m.LegFactor = &v } -func (m *InstrumentLeg) SetLegCreditRating(v string) { m.LegCreditRating = &v } -func (m *InstrumentLeg) SetLegInstrRegistry(v string) { m.LegInstrRegistry = &v } -func (m *InstrumentLeg) SetLegCountryOfIssue(v string) { m.LegCountryOfIssue = &v } -func (m *InstrumentLeg) SetLegStateOrProvinceOfIssue(v string) { m.LegStateOrProvinceOfIssue = &v } -func (m *InstrumentLeg) SetLegLocaleOfIssue(v string) { m.LegLocaleOfIssue = &v } -func (m *InstrumentLeg) SetLegRedemptionDate(v string) { m.LegRedemptionDate = &v } -func (m *InstrumentLeg) SetLegStrikePrice(v float64) { m.LegStrikePrice = &v } -func (m *InstrumentLeg) SetLegStrikeCurrency(v string) { m.LegStrikeCurrency = &v } -func (m *InstrumentLeg) SetLegOptAttribute(v string) { m.LegOptAttribute = &v } -func (m *InstrumentLeg) SetLegContractMultiplier(v float64) { m.LegContractMultiplier = &v } -func (m *InstrumentLeg) SetLegCouponRate(v float64) { m.LegCouponRate = &v } -func (m *InstrumentLeg) SetLegSecurityExchange(v string) { m.LegSecurityExchange = &v } -func (m *InstrumentLeg) SetLegIssuer(v string) { m.LegIssuer = &v } -func (m *InstrumentLeg) SetEncodedLegIssuerLen(v int) { m.EncodedLegIssuerLen = &v } -func (m *InstrumentLeg) SetEncodedLegIssuer(v string) { m.EncodedLegIssuer = &v } -func (m *InstrumentLeg) SetLegSecurityDesc(v string) { m.LegSecurityDesc = &v } -func (m *InstrumentLeg) SetEncodedLegSecurityDescLen(v int) { m.EncodedLegSecurityDescLen = &v } -func (m *InstrumentLeg) SetEncodedLegSecurityDesc(v string) { m.EncodedLegSecurityDesc = &v } -func (m *InstrumentLeg) SetLegRatioQty(v float64) { m.LegRatioQty = &v } -func (m *InstrumentLeg) SetLegSide(v string) { m.LegSide = &v } -func (m *InstrumentLeg) SetLegCurrency(v string) { m.LegCurrency = &v } -func (m *InstrumentLeg) SetLegPool(v string) { m.LegPool = &v } -func (m *InstrumentLeg) SetLegDatedDate(v string) { m.LegDatedDate = &v } -func (m *InstrumentLeg) SetLegContractSettlMonth(v string) { m.LegContractSettlMonth = &v } -func (m *InstrumentLeg) SetLegInterestAccrualDate(v string) { m.LegInterestAccrualDate = &v } -func (m *InstrumentLeg) SetLegUnitOfMeasure(v string) { m.LegUnitOfMeasure = &v } -func (m *InstrumentLeg) SetLegTimeUnit(v string) { m.LegTimeUnit = &v } -func (m *InstrumentLeg) SetLegOptionRatio(v float64) { m.LegOptionRatio = &v } -func (m *InstrumentLeg) SetLegPrice(v float64) { m.LegPrice = &v } -func (m *InstrumentLeg) SetLegMaturityTime(v string) { m.LegMaturityTime = &v } -func (m *InstrumentLeg) SetLegPutOrCall(v int) { m.LegPutOrCall = &v } -func (m *InstrumentLeg) SetLegExerciseStyle(v int) { m.LegExerciseStyle = &v } -func (m *InstrumentLeg) SetLegUnitOfMeasureQty(v float64) { m.LegUnitOfMeasureQty = &v } -func (m *InstrumentLeg) SetLegPriceUnitOfMeasure(v string) { m.LegPriceUnitOfMeasure = &v } -func (m *InstrumentLeg) SetLegPriceUnitOfMeasureQty(v float64) { m.LegPriceUnitOfMeasureQty = &v } +func (m *InstrumentLeg) SetLegSymbol(v string) { m.LegSymbol = &v } +func (m *InstrumentLeg) SetLegSymbolSfx(v string) { m.LegSymbolSfx = &v } +func (m *InstrumentLeg) SetLegSecurityID(v string) { m.LegSecurityID = &v } +func (m *InstrumentLeg) SetLegSecurityIDSource(v string) { m.LegSecurityIDSource = &v } +func (m *InstrumentLeg) SetLegProduct(v int) { m.LegProduct = &v } +func (m *InstrumentLeg) SetLegCFICode(v string) { m.LegCFICode = &v } +func (m *InstrumentLeg) SetLegSecurityType(v string) { m.LegSecurityType = &v } +func (m *InstrumentLeg) SetLegSecuritySubType(v string) { m.LegSecuritySubType = &v } +func (m *InstrumentLeg) SetLegMaturityMonthYear(v string) { m.LegMaturityMonthYear = &v } +func (m *InstrumentLeg) SetLegMaturityDate(v string) { m.LegMaturityDate = &v } +func (m *InstrumentLeg) SetLegCouponPaymentDate(v string) { m.LegCouponPaymentDate = &v } +func (m *InstrumentLeg) SetLegIssueDate(v string) { m.LegIssueDate = &v } +func (m *InstrumentLeg) SetLegRepoCollateralSecurityType(v int) { m.LegRepoCollateralSecurityType = &v } +func (m *InstrumentLeg) SetLegRepurchaseTerm(v int) { m.LegRepurchaseTerm = &v } +func (m *InstrumentLeg) SetLegRepurchaseRate(v float64) { m.LegRepurchaseRate = &v } +func (m *InstrumentLeg) SetLegFactor(v float64) { m.LegFactor = &v } +func (m *InstrumentLeg) SetLegCreditRating(v string) { m.LegCreditRating = &v } +func (m *InstrumentLeg) SetLegInstrRegistry(v string) { m.LegInstrRegistry = &v } +func (m *InstrumentLeg) SetLegCountryOfIssue(v string) { m.LegCountryOfIssue = &v } +func (m *InstrumentLeg) SetLegStateOrProvinceOfIssue(v string) { m.LegStateOrProvinceOfIssue = &v } +func (m *InstrumentLeg) SetLegLocaleOfIssue(v string) { m.LegLocaleOfIssue = &v } +func (m *InstrumentLeg) SetLegRedemptionDate(v string) { m.LegRedemptionDate = &v } +func (m *InstrumentLeg) SetLegStrikePrice(v float64) { m.LegStrikePrice = &v } +func (m *InstrumentLeg) SetLegStrikeCurrency(v string) { m.LegStrikeCurrency = &v } +func (m *InstrumentLeg) SetLegOptAttribute(v string) { m.LegOptAttribute = &v } +func (m *InstrumentLeg) SetLegContractMultiplier(v float64) { m.LegContractMultiplier = &v } +func (m *InstrumentLeg) SetLegCouponRate(v float64) { m.LegCouponRate = &v } +func (m *InstrumentLeg) SetLegSecurityExchange(v string) { m.LegSecurityExchange = &v } +func (m *InstrumentLeg) SetLegIssuer(v string) { m.LegIssuer = &v } +func (m *InstrumentLeg) SetEncodedLegIssuerLen(v int) { m.EncodedLegIssuerLen = &v } +func (m *InstrumentLeg) SetEncodedLegIssuer(v string) { m.EncodedLegIssuer = &v } +func (m *InstrumentLeg) SetLegSecurityDesc(v string) { m.LegSecurityDesc = &v } +func (m *InstrumentLeg) SetEncodedLegSecurityDescLen(v int) { m.EncodedLegSecurityDescLen = &v } +func (m *InstrumentLeg) SetEncodedLegSecurityDesc(v string) { m.EncodedLegSecurityDesc = &v } +func (m *InstrumentLeg) SetLegRatioQty(v float64) { m.LegRatioQty = &v } +func (m *InstrumentLeg) SetLegSide(v string) { m.LegSide = &v } +func (m *InstrumentLeg) SetLegCurrency(v string) { m.LegCurrency = &v } +func (m *InstrumentLeg) SetLegPool(v string) { m.LegPool = &v } +func (m *InstrumentLeg) SetLegDatedDate(v string) { m.LegDatedDate = &v } +func (m *InstrumentLeg) SetLegContractSettlMonth(v string) { m.LegContractSettlMonth = &v } +func (m *InstrumentLeg) SetLegInterestAccrualDate(v string) { m.LegInterestAccrualDate = &v } +func (m *InstrumentLeg) SetLegUnitOfMeasure(v string) { m.LegUnitOfMeasure = &v } +func (m *InstrumentLeg) SetLegTimeUnit(v string) { m.LegTimeUnit = &v } +func (m *InstrumentLeg) SetLegOptionRatio(v float64) { m.LegOptionRatio = &v } +func (m *InstrumentLeg) SetLegPrice(v float64) { m.LegPrice = &v } +func (m *InstrumentLeg) SetLegMaturityTime(v string) { m.LegMaturityTime = &v } +func (m *InstrumentLeg) SetLegPutOrCall(v int) { m.LegPutOrCall = &v } +func (m *InstrumentLeg) SetLegExerciseStyle(v int) { m.LegExerciseStyle = &v } +func (m *InstrumentLeg) SetLegUnitOfMeasureQty(v float64) { m.LegUnitOfMeasureQty = &v } +func (m *InstrumentLeg) SetLegPriceUnitOfMeasure(v string) { m.LegPriceUnitOfMeasure = &v } +func (m *InstrumentLeg) SetLegPriceUnitOfMeasureQty(v float64) { m.LegPriceUnitOfMeasureQty = &v } diff --git a/fix50sp1/securitytradingrules/SecurityTradingRules.go b/fix50sp1/securitytradingrules/SecurityTradingRules.go index 441ccdec6..d4f2bed87 100644 --- a/fix50sp1/securitytradingrules/SecurityTradingRules.go +++ b/fix50sp1/securitytradingrules/SecurityTradingRules.go @@ -1,106 +1,17 @@ package securitytradingrules import ( - "github.com/quickfixgo/quickfix/fix50sp1/tradingsessionrules" + "github.com/quickfixgo/quickfix/fix50sp1/basetradingrules" + "github.com/quickfixgo/quickfix/fix50sp1/nestedinstrumentattribute" + "github.com/quickfixgo/quickfix/fix50sp1/tradingsessionrulesgrp" ) -//NoTickRules is a repeating group in SecurityTradingRules -type NoTickRules struct { - //StartTickPriceRange is a non-required field for NoTickRules. - StartTickPriceRange *float64 `fix:"1206"` - //EndTickPriceRange is a non-required field for NoTickRules. - EndTickPriceRange *float64 `fix:"1207"` - //TickIncrement is a non-required field for NoTickRules. - TickIncrement *float64 `fix:"1208"` - //TickRuleType is a non-required field for NoTickRules. - TickRuleType *int `fix:"1209"` -} - -//NoLotTypeRules is a repeating group in SecurityTradingRules -type NoLotTypeRules struct { - //LotType is a non-required field for NoLotTypeRules. - LotType *string `fix:"1093"` - //MinLotSize is a non-required field for NoLotTypeRules. - MinLotSize *float64 `fix:"1231"` -} - -//NoTradingSessionRules is a repeating group in SecurityTradingRules -type NoTradingSessionRules struct { - //TradingSessionID is a non-required field for NoTradingSessionRules. - TradingSessionID *string `fix:"336"` - //TradingSessionSubID is a non-required field for NoTradingSessionRules. - TradingSessionSubID *string `fix:"625"` - //TradingSessionRules Component - tradingsessionrules.TradingSessionRules -} - -//NoNestedInstrAttrib is a repeating group in SecurityTradingRules -type NoNestedInstrAttrib struct { - //NestedInstrAttribType is a non-required field for NoNestedInstrAttrib. - NestedInstrAttribType *int `fix:"1210"` - //NestedInstrAttribValue is a non-required field for NoNestedInstrAttrib. - NestedInstrAttribValue *string `fix:"1211"` -} - //SecurityTradingRules is a fix50sp1 Component type SecurityTradingRules struct { - //NoTickRules is a non-required field for SecurityTradingRules. - NoTickRules []NoTickRules `fix:"1205,omitempty"` - //NoLotTypeRules is a non-required field for SecurityTradingRules. - NoLotTypeRules []NoLotTypeRules `fix:"1234,omitempty"` - //PriceLimitType is a non-required field for SecurityTradingRules. - PriceLimitType *int `fix:"1306"` - //LowLimitPrice is a non-required field for SecurityTradingRules. - LowLimitPrice *float64 `fix:"1148"` - //HighLimitPrice is a non-required field for SecurityTradingRules. - HighLimitPrice *float64 `fix:"1149"` - //TradingReferencePrice is a non-required field for SecurityTradingRules. - TradingReferencePrice *float64 `fix:"1150"` - //ExpirationCycle is a non-required field for SecurityTradingRules. - ExpirationCycle *int `fix:"827"` - //MinTradeVol is a non-required field for SecurityTradingRules. - MinTradeVol *float64 `fix:"562"` - //MaxTradeVol is a non-required field for SecurityTradingRules. - MaxTradeVol *float64 `fix:"1140"` - //MaxPriceVariation is a non-required field for SecurityTradingRules. - MaxPriceVariation *float64 `fix:"1143"` - //ImpliedMarketIndicator is a non-required field for SecurityTradingRules. - ImpliedMarketIndicator *int `fix:"1144"` - //TradingCurrency is a non-required field for SecurityTradingRules. - TradingCurrency *string `fix:"1245"` - //RoundLot is a non-required field for SecurityTradingRules. - RoundLot *float64 `fix:"561"` - //MultilegModel is a non-required field for SecurityTradingRules. - MultilegModel *int `fix:"1377"` - //MultilegPriceMethod is a non-required field for SecurityTradingRules. - MultilegPriceMethod *int `fix:"1378"` - //PriceType is a non-required field for SecurityTradingRules. - PriceType *int `fix:"423"` - //NoTradingSessionRules is a non-required field for SecurityTradingRules. - NoTradingSessionRules []NoTradingSessionRules `fix:"1309,omitempty"` - //NoNestedInstrAttrib is a non-required field for SecurityTradingRules. - NoNestedInstrAttrib []NoNestedInstrAttrib `fix:"1312,omitempty"` -} - -func (m *SecurityTradingRules) SetNoTickRules(v []NoTickRules) { m.NoTickRules = v } -func (m *SecurityTradingRules) SetNoLotTypeRules(v []NoLotTypeRules) { m.NoLotTypeRules = v } -func (m *SecurityTradingRules) SetPriceLimitType(v int) { m.PriceLimitType = &v } -func (m *SecurityTradingRules) SetLowLimitPrice(v float64) { m.LowLimitPrice = &v } -func (m *SecurityTradingRules) SetHighLimitPrice(v float64) { m.HighLimitPrice = &v } -func (m *SecurityTradingRules) SetTradingReferencePrice(v float64) { m.TradingReferencePrice = &v } -func (m *SecurityTradingRules) SetExpirationCycle(v int) { m.ExpirationCycle = &v } -func (m *SecurityTradingRules) SetMinTradeVol(v float64) { m.MinTradeVol = &v } -func (m *SecurityTradingRules) SetMaxTradeVol(v float64) { m.MaxTradeVol = &v } -func (m *SecurityTradingRules) SetMaxPriceVariation(v float64) { m.MaxPriceVariation = &v } -func (m *SecurityTradingRules) SetImpliedMarketIndicator(v int) { m.ImpliedMarketIndicator = &v } -func (m *SecurityTradingRules) SetTradingCurrency(v string) { m.TradingCurrency = &v } -func (m *SecurityTradingRules) SetRoundLot(v float64) { m.RoundLot = &v } -func (m *SecurityTradingRules) SetMultilegModel(v int) { m.MultilegModel = &v } -func (m *SecurityTradingRules) SetMultilegPriceMethod(v int) { m.MultilegPriceMethod = &v } -func (m *SecurityTradingRules) SetPriceType(v int) { m.PriceType = &v } -func (m *SecurityTradingRules) SetNoTradingSessionRules(v []NoTradingSessionRules) { - m.NoTradingSessionRules = v -} -func (m *SecurityTradingRules) SetNoNestedInstrAttrib(v []NoNestedInstrAttrib) { - m.NoNestedInstrAttrib = v + //BaseTradingRules Component + basetradingrules.BaseTradingRules + //TradingSessionRulesGrp Component + tradingsessionrulesgrp.TradingSessionRulesGrp + //NestedInstrumentAttribute Component + nestedinstrumentattribute.NestedInstrumentAttribute } diff --git a/fix50sp1/settlinstructionsdata/SettlInstructionsData.go b/fix50sp1/settlinstructionsdata/SettlInstructionsData.go index 08e05ce3b..b3a9c6a01 100644 --- a/fix50sp1/settlinstructionsdata/SettlInstructionsData.go +++ b/fix50sp1/settlinstructionsdata/SettlInstructionsData.go @@ -1,19 +1,9 @@ package settlinstructionsdata import ( - "github.com/quickfixgo/quickfix/fix50sp1/settlparties" + "github.com/quickfixgo/quickfix/fix50sp1/dlvyinstgrp" ) -//NoDlvyInst is a repeating group in SettlInstructionsData -type NoDlvyInst struct { - //SettlInstSource is a non-required field for NoDlvyInst. - SettlInstSource *string `fix:"165"` - //DlvyInstType is a non-required field for NoDlvyInst. - DlvyInstType *string `fix:"787"` - //SettlParties Component - settlparties.SettlParties -} - //SettlInstructionsData is a fix50sp1 Component type SettlInstructionsData struct { //SettlDeliveryType is a non-required field for SettlInstructionsData. @@ -24,12 +14,11 @@ type SettlInstructionsData struct { StandInstDbName *string `fix:"170"` //StandInstDbID is a non-required field for SettlInstructionsData. StandInstDbID *string `fix:"171"` - //NoDlvyInst is a non-required field for SettlInstructionsData. - NoDlvyInst []NoDlvyInst `fix:"85,omitempty"` + //DlvyInstGrp Component + dlvyinstgrp.DlvyInstGrp } -func (m *SettlInstructionsData) SetSettlDeliveryType(v int) { m.SettlDeliveryType = &v } -func (m *SettlInstructionsData) SetStandInstDbType(v int) { m.StandInstDbType = &v } -func (m *SettlInstructionsData) SetStandInstDbName(v string) { m.StandInstDbName = &v } -func (m *SettlInstructionsData) SetStandInstDbID(v string) { m.StandInstDbID = &v } -func (m *SettlInstructionsData) SetNoDlvyInst(v []NoDlvyInst) { m.NoDlvyInst = v } +func (m *SettlInstructionsData) SetSettlDeliveryType(v int) { m.SettlDeliveryType = &v } +func (m *SettlInstructionsData) SetStandInstDbType(v int) { m.StandInstDbType = &v } +func (m *SettlInstructionsData) SetStandInstDbName(v string) { m.StandInstDbName = &v } +func (m *SettlInstructionsData) SetStandInstDbID(v string) { m.StandInstDbID = &v } diff --git a/fix50sp1/tradingsessionrules/TradingSessionRules.go b/fix50sp1/tradingsessionrules/TradingSessionRules.go index d7d247119..0eb2f5312 100644 --- a/fix50sp1/tradingsessionrules/TradingSessionRules.go +++ b/fix50sp1/tradingsessionrules/TradingSessionRules.go @@ -1,57 +1,23 @@ package tradingsessionrules -//NoOrdTypeRules is a repeating group in TradingSessionRules -type NoOrdTypeRules struct { - //OrdType is a non-required field for NoOrdTypeRules. - OrdType *string `fix:"40"` -} - -//NoTimeInForceRules is a repeating group in TradingSessionRules -type NoTimeInForceRules struct { - //TimeInForce is a non-required field for NoTimeInForceRules. - TimeInForce *string `fix:"59"` -} - -//NoExecInstRules is a repeating group in TradingSessionRules -type NoExecInstRules struct { - //ExecInstValue is a non-required field for NoExecInstRules. - ExecInstValue *string `fix:"1308"` -} - -//NoMatchRules is a repeating group in TradingSessionRules -type NoMatchRules struct { - //MatchAlgorithm is a non-required field for NoMatchRules. - MatchAlgorithm *string `fix:"1142"` - //MatchType is a non-required field for NoMatchRules. - MatchType *string `fix:"574"` -} - -//NoMDFeedTypes is a repeating group in TradingSessionRules -type NoMDFeedTypes struct { - //MDFeedType is a non-required field for NoMDFeedTypes. - MDFeedType *string `fix:"1022"` - //MarketDepth is a non-required field for NoMDFeedTypes. - MarketDepth *int `fix:"264"` - //MDBookType is a non-required field for NoMDFeedTypes. - MDBookType *int `fix:"1021"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp1/execinstrules" + "github.com/quickfixgo/quickfix/fix50sp1/marketdatafeedtypes" + "github.com/quickfixgo/quickfix/fix50sp1/matchrules" + "github.com/quickfixgo/quickfix/fix50sp1/ordtyperules" + "github.com/quickfixgo/quickfix/fix50sp1/timeinforcerules" +) //TradingSessionRules is a fix50sp1 Component type TradingSessionRules struct { - //NoOrdTypeRules is a non-required field for TradingSessionRules. - NoOrdTypeRules []NoOrdTypeRules `fix:"1237,omitempty"` - //NoTimeInForceRules is a non-required field for TradingSessionRules. - NoTimeInForceRules []NoTimeInForceRules `fix:"1239,omitempty"` - //NoExecInstRules is a non-required field for TradingSessionRules. - NoExecInstRules []NoExecInstRules `fix:"1232,omitempty"` - //NoMatchRules is a non-required field for TradingSessionRules. - NoMatchRules []NoMatchRules `fix:"1235,omitempty"` - //NoMDFeedTypes is a non-required field for TradingSessionRules. - NoMDFeedTypes []NoMDFeedTypes `fix:"1141,omitempty"` + //OrdTypeRules Component + ordtyperules.OrdTypeRules + //TimeInForceRules Component + timeinforcerules.TimeInForceRules + //ExecInstRules Component + execinstrules.ExecInstRules + //MatchRules Component + matchrules.MatchRules + //MarketDataFeedTypes Component + marketdatafeedtypes.MarketDataFeedTypes } - -func (m *TradingSessionRules) SetNoOrdTypeRules(v []NoOrdTypeRules) { m.NoOrdTypeRules = v } -func (m *TradingSessionRules) SetNoTimeInForceRules(v []NoTimeInForceRules) { m.NoTimeInForceRules = v } -func (m *TradingSessionRules) SetNoExecInstRules(v []NoExecInstRules) { m.NoExecInstRules = v } -func (m *TradingSessionRules) SetNoMatchRules(v []NoMatchRules) { m.NoMatchRules = v } -func (m *TradingSessionRules) SetNoMDFeedTypes(v []NoMDFeedTypes) { m.NoMDFeedTypes = v } diff --git a/fix50sp1/underlyinginstrument/UnderlyingInstrument.go b/fix50sp1/underlyinginstrument/UnderlyingInstrument.go index 24a12026c..0e5aa181f 100644 --- a/fix50sp1/underlyinginstrument/UnderlyingInstrument.go +++ b/fix50sp1/underlyinginstrument/UnderlyingInstrument.go @@ -1,37 +1,11 @@ package underlyinginstrument import ( - "github.com/quickfixgo/quickfix/fix50sp1/undlyinstrumentptyssubgrp" + "github.com/quickfixgo/quickfix/fix50sp1/underlyingstipulations" + "github.com/quickfixgo/quickfix/fix50sp1/undlyinstrumentparties" + "github.com/quickfixgo/quickfix/fix50sp1/undsecaltidgrp" ) -//NoUnderlyingSecurityAltID is a repeating group in UnderlyingInstrument -type NoUnderlyingSecurityAltID struct { - //UnderlyingSecurityAltID is a non-required field for NoUnderlyingSecurityAltID. - UnderlyingSecurityAltID *string `fix:"458"` - //UnderlyingSecurityAltIDSource is a non-required field for NoUnderlyingSecurityAltID. - UnderlyingSecurityAltIDSource *string `fix:"459"` -} - -//NoUnderlyingStips is a repeating group in UnderlyingInstrument -type NoUnderlyingStips struct { - //UnderlyingStipType is a non-required field for NoUnderlyingStips. - UnderlyingStipType *string `fix:"888"` - //UnderlyingStipValue is a non-required field for NoUnderlyingStips. - UnderlyingStipValue *string `fix:"889"` -} - -//NoUndlyInstrumentParties is a repeating group in UnderlyingInstrument -type NoUndlyInstrumentParties struct { - //UndlyInstrumentPartyID is a non-required field for NoUndlyInstrumentParties. - UndlyInstrumentPartyID *string `fix:"1059"` - //UndlyInstrumentPartyIDSource is a non-required field for NoUndlyInstrumentParties. - UndlyInstrumentPartyIDSource *string `fix:"1060"` - //UndlyInstrumentPartyRole is a non-required field for NoUndlyInstrumentParties. - UndlyInstrumentPartyRole *int `fix:"1061"` - //UndlyInstrumentPtysSubGrp Component - undlyinstrumentptyssubgrp.UndlyInstrumentPtysSubGrp -} - //UnderlyingInstrument is a fix50sp1 Component type UnderlyingInstrument struct { //UnderlyingSymbol is a non-required field for UnderlyingInstrument. @@ -42,8 +16,8 @@ type UnderlyingInstrument struct { UnderlyingSecurityID *string `fix:"309"` //UnderlyingSecurityIDSource is a non-required field for UnderlyingInstrument. UnderlyingSecurityIDSource *string `fix:"305"` - //NoUnderlyingSecurityAltID is a non-required field for UnderlyingInstrument. - NoUnderlyingSecurityAltID []NoUnderlyingSecurityAltID `fix:"457,omitempty"` + //UndSecAltIDGrp Component + undsecaltidgrp.UndSecAltIDGrp //UnderlyingProduct is a non-required field for UnderlyingInstrument. UnderlyingProduct *int `fix:"462"` //UnderlyingCFICode is a non-required field for UnderlyingInstrument. @@ -124,8 +98,8 @@ type UnderlyingInstrument struct { UnderlyingCurrentValue *float64 `fix:"885"` //UnderlyingEndValue is a non-required field for UnderlyingInstrument. UnderlyingEndValue *float64 `fix:"886"` - //NoUnderlyingStips is a non-required field for UnderlyingInstrument. - NoUnderlyingStips []NoUnderlyingStips `fix:"887,omitempty"` + //UnderlyingStipulations Component + underlyingstipulations.UnderlyingStipulations //UnderlyingAllocationPercent is a non-required field for UnderlyingInstrument. UnderlyingAllocationPercent *float64 `fix:"972"` //UnderlyingSettlementType is a non-required field for UnderlyingInstrument. @@ -140,8 +114,8 @@ type UnderlyingInstrument struct { UnderlyingTimeUnit *string `fix:"1000"` //UnderlyingCapValue is a non-required field for UnderlyingInstrument. UnderlyingCapValue *float64 `fix:"1038"` - //NoUndlyInstrumentParties is a non-required field for UnderlyingInstrument. - NoUndlyInstrumentParties []NoUndlyInstrumentParties `fix:"1058,omitempty"` + //UndlyInstrumentParties Component + undlyinstrumentparties.UndlyInstrumentParties //UnderlyingSettlMethod is a non-required field for UnderlyingInstrument. UnderlyingSettlMethod *string `fix:"1039"` //UnderlyingAdjustedQuantity is a non-required field for UnderlyingInstrument. @@ -170,9 +144,6 @@ func (m *UnderlyingInstrument) SetUnderlyingSecurityID(v string) { m.UnderlyingS func (m *UnderlyingInstrument) SetUnderlyingSecurityIDSource(v string) { m.UnderlyingSecurityIDSource = &v } -func (m *UnderlyingInstrument) SetNoUnderlyingSecurityAltID(v []NoUnderlyingSecurityAltID) { - m.NoUnderlyingSecurityAltID = v -} func (m *UnderlyingInstrument) SetUnderlyingProduct(v int) { m.UnderlyingProduct = &v } func (m *UnderlyingInstrument) SetUnderlyingCFICode(v string) { m.UnderlyingCFICode = &v } func (m *UnderlyingInstrument) SetUnderlyingSecurityType(v string) { m.UnderlyingSecurityType = &v } @@ -221,17 +192,16 @@ func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDescLen(v int) { func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDesc(v string) { m.EncodedUnderlyingSecurityDesc = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } -func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } -func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } -func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } -func (m *UnderlyingInstrument) SetNoUnderlyingStips(v []NoUnderlyingStips) { m.NoUnderlyingStips = v } +func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } +func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } +func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } +func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } +func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } func (m *UnderlyingInstrument) SetUnderlyingAllocationPercent(v float64) { m.UnderlyingAllocationPercent = &v } @@ -241,10 +211,7 @@ func (m *UnderlyingInstrument) SetUnderlyingCashType(v string) { m.Underlyi func (m *UnderlyingInstrument) SetUnderlyingUnitOfMeasure(v string) { m.UnderlyingUnitOfMeasure = &v } func (m *UnderlyingInstrument) SetUnderlyingTimeUnit(v string) { m.UnderlyingTimeUnit = &v } func (m *UnderlyingInstrument) SetUnderlyingCapValue(v float64) { m.UnderlyingCapValue = &v } -func (m *UnderlyingInstrument) SetNoUndlyInstrumentParties(v []NoUndlyInstrumentParties) { - m.NoUndlyInstrumentParties = v -} -func (m *UnderlyingInstrument) SetUnderlyingSettlMethod(v string) { m.UnderlyingSettlMethod = &v } +func (m *UnderlyingInstrument) SetUnderlyingSettlMethod(v string) { m.UnderlyingSettlMethod = &v } func (m *UnderlyingInstrument) SetUnderlyingAdjustedQuantity(v float64) { m.UnderlyingAdjustedQuantity = &v } diff --git a/fix50sp1/underlyingleginstrument/UnderlyingLegInstrument.go b/fix50sp1/underlyingleginstrument/UnderlyingLegInstrument.go index 271f8a921..f89fd406a 100644 --- a/fix50sp1/underlyingleginstrument/UnderlyingLegInstrument.go +++ b/fix50sp1/underlyingleginstrument/UnderlyingLegInstrument.go @@ -1,12 +1,8 @@ package underlyingleginstrument -//NoUnderlyingLegSecurityAltID is a repeating group in UnderlyingLegInstrument -type NoUnderlyingLegSecurityAltID struct { - //UnderlyingLegSecurityAltID is a non-required field for NoUnderlyingLegSecurityAltID. - UnderlyingLegSecurityAltID *string `fix:"1335"` - //UnderlyingLegSecurityAltIDSource is a non-required field for NoUnderlyingLegSecurityAltID. - UnderlyingLegSecurityAltIDSource *string `fix:"1336"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp1/underlyinglegsecurityaltidgrp" +) //UnderlyingLegInstrument is a fix50sp1 Component type UnderlyingLegInstrument struct { @@ -18,8 +14,8 @@ type UnderlyingLegInstrument struct { UnderlyingLegSecurityID *string `fix:"1332"` //UnderlyingLegSecurityIDSource is a non-required field for UnderlyingLegInstrument. UnderlyingLegSecurityIDSource *string `fix:"1333"` - //NoUnderlyingLegSecurityAltID is a non-required field for UnderlyingLegInstrument. - NoUnderlyingLegSecurityAltID []NoUnderlyingLegSecurityAltID `fix:"1334,omitempty"` + //UnderlyingLegSecurityAltIDGrp Component + underlyinglegsecurityaltidgrp.UnderlyingLegSecurityAltIDGrp //UnderlyingLegCFICode is a non-required field for UnderlyingLegInstrument. UnderlyingLegCFICode *string `fix:"1344"` //UnderlyingLegSecurityType is a non-required field for UnderlyingLegInstrument. @@ -50,9 +46,6 @@ func (m *UnderlyingLegInstrument) SetUnderlyingLegSecurityID(v string) { m.Under func (m *UnderlyingLegInstrument) SetUnderlyingLegSecurityIDSource(v string) { m.UnderlyingLegSecurityIDSource = &v } -func (m *UnderlyingLegInstrument) SetNoUnderlyingLegSecurityAltID(v []NoUnderlyingLegSecurityAltID) { - m.NoUnderlyingLegSecurityAltID = v -} func (m *UnderlyingLegInstrument) SetUnderlyingLegCFICode(v string) { m.UnderlyingLegCFICode = &v } func (m *UnderlyingLegInstrument) SetUnderlyingLegSecurityType(v string) { m.UnderlyingLegSecurityType = &v diff --git a/fix50sp2/basetradingrules/BaseTradingRules.go b/fix50sp2/basetradingrules/BaseTradingRules.go index 8ed9a7d98..fe8ef9d1b 100644 --- a/fix50sp2/basetradingrules/BaseTradingRules.go +++ b/fix50sp2/basetradingrules/BaseTradingRules.go @@ -1,39 +1,19 @@ package basetradingrules -//NoTickRules is a repeating group in BaseTradingRules -type NoTickRules struct { - //StartTickPriceRange is a non-required field for NoTickRules. - StartTickPriceRange *float64 `fix:"1206"` - //EndTickPriceRange is a non-required field for NoTickRules. - EndTickPriceRange *float64 `fix:"1207"` - //TickIncrement is a non-required field for NoTickRules. - TickIncrement *float64 `fix:"1208"` - //TickRuleType is a non-required field for NoTickRules. - TickRuleType *int `fix:"1209"` -} - -//NoLotTypeRules is a repeating group in BaseTradingRules -type NoLotTypeRules struct { - //LotType is a non-required field for NoLotTypeRules. - LotType *string `fix:"1093"` - //MinLotSize is a non-required field for NoLotTypeRules. - MinLotSize *float64 `fix:"1231"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp2/lottyperules" + "github.com/quickfixgo/quickfix/fix50sp2/pricelimits" + "github.com/quickfixgo/quickfix/fix50sp2/tickrules" +) //BaseTradingRules is a fix50sp2 Component type BaseTradingRules struct { - //NoTickRules is a non-required field for BaseTradingRules. - NoTickRules []NoTickRules `fix:"1205,omitempty"` - //NoLotTypeRules is a non-required field for BaseTradingRules. - NoLotTypeRules []NoLotTypeRules `fix:"1234,omitempty"` - //PriceLimitType is a non-required field for BaseTradingRules. - PriceLimitType *int `fix:"1306"` - //LowLimitPrice is a non-required field for BaseTradingRules. - LowLimitPrice *float64 `fix:"1148"` - //HighLimitPrice is a non-required field for BaseTradingRules. - HighLimitPrice *float64 `fix:"1149"` - //TradingReferencePrice is a non-required field for BaseTradingRules. - TradingReferencePrice *float64 `fix:"1150"` + //TickRules Component + tickrules.TickRules + //LotTypeRules Component + lottyperules.LotTypeRules + //PriceLimits Component + pricelimits.PriceLimits //ExpirationCycle is a non-required field for BaseTradingRules. ExpirationCycle *int `fix:"827"` //MinTradeVol is a non-required field for BaseTradingRules. @@ -56,19 +36,13 @@ type BaseTradingRules struct { PriceType *int `fix:"423"` } -func (m *BaseTradingRules) SetNoTickRules(v []NoTickRules) { m.NoTickRules = v } -func (m *BaseTradingRules) SetNoLotTypeRules(v []NoLotTypeRules) { m.NoLotTypeRules = v } -func (m *BaseTradingRules) SetPriceLimitType(v int) { m.PriceLimitType = &v } -func (m *BaseTradingRules) SetLowLimitPrice(v float64) { m.LowLimitPrice = &v } -func (m *BaseTradingRules) SetHighLimitPrice(v float64) { m.HighLimitPrice = &v } -func (m *BaseTradingRules) SetTradingReferencePrice(v float64) { m.TradingReferencePrice = &v } -func (m *BaseTradingRules) SetExpirationCycle(v int) { m.ExpirationCycle = &v } -func (m *BaseTradingRules) SetMinTradeVol(v float64) { m.MinTradeVol = &v } -func (m *BaseTradingRules) SetMaxTradeVol(v float64) { m.MaxTradeVol = &v } -func (m *BaseTradingRules) SetMaxPriceVariation(v float64) { m.MaxPriceVariation = &v } -func (m *BaseTradingRules) SetImpliedMarketIndicator(v int) { m.ImpliedMarketIndicator = &v } -func (m *BaseTradingRules) SetTradingCurrency(v string) { m.TradingCurrency = &v } -func (m *BaseTradingRules) SetRoundLot(v float64) { m.RoundLot = &v } -func (m *BaseTradingRules) SetMultilegModel(v int) { m.MultilegModel = &v } -func (m *BaseTradingRules) SetMultilegPriceMethod(v int) { m.MultilegPriceMethod = &v } -func (m *BaseTradingRules) SetPriceType(v int) { m.PriceType = &v } +func (m *BaseTradingRules) SetExpirationCycle(v int) { m.ExpirationCycle = &v } +func (m *BaseTradingRules) SetMinTradeVol(v float64) { m.MinTradeVol = &v } +func (m *BaseTradingRules) SetMaxTradeVol(v float64) { m.MaxTradeVol = &v } +func (m *BaseTradingRules) SetMaxPriceVariation(v float64) { m.MaxPriceVariation = &v } +func (m *BaseTradingRules) SetImpliedMarketIndicator(v int) { m.ImpliedMarketIndicator = &v } +func (m *BaseTradingRules) SetTradingCurrency(v string) { m.TradingCurrency = &v } +func (m *BaseTradingRules) SetRoundLot(v float64) { m.RoundLot = &v } +func (m *BaseTradingRules) SetMultilegModel(v int) { m.MultilegModel = &v } +func (m *BaseTradingRules) SetMultilegPriceMethod(v int) { m.MultilegPriceMethod = &v } +func (m *BaseTradingRules) SetPriceType(v int) { m.PriceType = &v } diff --git a/fix50sp2/derivativeinstrument/DerivativeInstrument.go b/fix50sp2/derivativeinstrument/DerivativeInstrument.go index c72c0ca4b..8ef28c6e7 100644 --- a/fix50sp2/derivativeinstrument/DerivativeInstrument.go +++ b/fix50sp2/derivativeinstrument/DerivativeInstrument.go @@ -1,44 +1,12 @@ package derivativeinstrument import ( - "github.com/quickfixgo/quickfix/fix50sp2/derivativeinstrumentpartysubidsgrp" - "time" + "github.com/quickfixgo/quickfix/fix50sp2/derivativeeventsgrp" + "github.com/quickfixgo/quickfix/fix50sp2/derivativeinstrumentparties" + "github.com/quickfixgo/quickfix/fix50sp2/derivativesecurityaltidgrp" + "github.com/quickfixgo/quickfix/fix50sp2/derivativesecurityxml" ) -//NoDerivativeSecurityAltID is a repeating group in DerivativeInstrument -type NoDerivativeSecurityAltID struct { - //DerivativeSecurityAltID is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltID *string `fix:"1219"` - //DerivativeSecurityAltIDSource is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltIDSource *string `fix:"1220"` -} - -//NoDerivativeEvents is a repeating group in DerivativeInstrument -type NoDerivativeEvents struct { - //DerivativeEventType is a non-required field for NoDerivativeEvents. - DerivativeEventType *int `fix:"1287"` - //DerivativeEventDate is a non-required field for NoDerivativeEvents. - DerivativeEventDate *string `fix:"1288"` - //DerivativeEventTime is a non-required field for NoDerivativeEvents. - DerivativeEventTime *time.Time `fix:"1289"` - //DerivativeEventPx is a non-required field for NoDerivativeEvents. - DerivativeEventPx *float64 `fix:"1290"` - //DerivativeEventText is a non-required field for NoDerivativeEvents. - DerivativeEventText *string `fix:"1291"` -} - -//NoDerivativeInstrumentParties is a repeating group in DerivativeInstrument -type NoDerivativeInstrumentParties struct { - //DerivativeInstrumentPartyID is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyID *string `fix:"1293"` - //DerivativeInstrumentPartyIDSource is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyIDSource *string `fix:"1294"` - //DerivativeInstrumentPartyRole is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyRole *int `fix:"1295"` - //DerivativeInstrumentPartySubIDsGrp Component - derivativeinstrumentpartysubidsgrp.DerivativeInstrumentPartySubIDsGrp -} - //DerivativeInstrument is a fix50sp2 Component type DerivativeInstrument struct { //DerivativeSymbol is a non-required field for DerivativeInstrument. @@ -49,8 +17,8 @@ type DerivativeInstrument struct { DerivativeSecurityID *string `fix:"1216"` //DerivativeSecurityIDSource is a non-required field for DerivativeInstrument. DerivativeSecurityIDSource *string `fix:"1217"` - //NoDerivativeSecurityAltID is a non-required field for DerivativeInstrument. - NoDerivativeSecurityAltID []NoDerivativeSecurityAltID `fix:"1218,omitempty"` + //DerivativeSecurityAltIDGrp Component + derivativesecurityaltidgrp.DerivativeSecurityAltIDGrp //DerivativeProduct is a non-required field for DerivativeInstrument. DerivativeProduct *int `fix:"1246"` //DerivativeProductComplex is a non-required field for DerivativeInstrument. @@ -137,10 +105,10 @@ type DerivativeInstrument struct { DerivativeEncodedSecurityDesc *string `fix:"1281"` //DerivativeContractSettlMonth is a non-required field for DerivativeInstrument. DerivativeContractSettlMonth *string `fix:"1285"` - //NoDerivativeEvents is a non-required field for DerivativeInstrument. - NoDerivativeEvents []NoDerivativeEvents `fix:"1286,omitempty"` - //NoDerivativeInstrumentParties is a non-required field for DerivativeInstrument. - NoDerivativeInstrumentParties []NoDerivativeInstrumentParties `fix:"1292,omitempty"` + //DerivativeEventsGrp Component + derivativeeventsgrp.DerivativeEventsGrp + //DerivativeInstrumentParties Component + derivativeinstrumentparties.DerivativeInstrumentParties //DerivativeSettlMethod is a non-required field for DerivativeInstrument. DerivativeSettlMethod *string `fix:"1317"` //DerivativePriceQuoteMethod is a non-required field for DerivativeInstrument. @@ -155,12 +123,8 @@ type DerivativeInstrument struct { DerivativeFloorPrice *float64 `fix:"1322"` //DerivativePutOrCall is a non-required field for DerivativeInstrument. DerivativePutOrCall *int `fix:"1323"` - //DerivativeSecurityXMLLen is a non-required field for DerivativeInstrument. - DerivativeSecurityXMLLen *int `fix:"1282"` - //DerivativeSecurityXML is a non-required field for DerivativeInstrument. - DerivativeSecurityXML *string `fix:"1283"` - //DerivativeSecurityXMLSchema is a non-required field for DerivativeInstrument. - DerivativeSecurityXMLSchema *string `fix:"1284"` + //DerivativeSecurityXML Component + derivativesecurityxml.DerivativeSecurityXML //DerivativeContractMultiplierUnit is a non-required field for DerivativeInstrument. DerivativeContractMultiplierUnit *int `fix:"1438"` //DerivativeFlowScheduleType is a non-required field for DerivativeInstrument. @@ -173,9 +137,6 @@ func (m *DerivativeInstrument) SetDerivativeSecurityID(v string) { m.DerivativeS func (m *DerivativeInstrument) SetDerivativeSecurityIDSource(v string) { m.DerivativeSecurityIDSource = &v } -func (m *DerivativeInstrument) SetNoDerivativeSecurityAltID(v []NoDerivativeSecurityAltID) { - m.NoDerivativeSecurityAltID = v -} func (m *DerivativeInstrument) SetDerivativeProduct(v int) { m.DerivativeProduct = &v } func (m *DerivativeInstrument) SetDerivativeProductComplex(v string) { m.DerivativeProductComplex = &v } func (m *DerivativeInstrument) SetDerivFlexProductEligibilityIndicator(v bool) { @@ -253,10 +214,6 @@ func (m *DerivativeInstrument) SetDerivativeEncodedSecurityDesc(v string) { func (m *DerivativeInstrument) SetDerivativeContractSettlMonth(v string) { m.DerivativeContractSettlMonth = &v } -func (m *DerivativeInstrument) SetNoDerivativeEvents(v []NoDerivativeEvents) { m.NoDerivativeEvents = v } -func (m *DerivativeInstrument) SetNoDerivativeInstrumentParties(v []NoDerivativeInstrumentParties) { - m.NoDerivativeInstrumentParties = v -} func (m *DerivativeInstrument) SetDerivativeSettlMethod(v string) { m.DerivativeSettlMethod = &v } func (m *DerivativeInstrument) SetDerivativePriceQuoteMethod(v string) { m.DerivativePriceQuoteMethod = &v @@ -268,11 +225,6 @@ func (m *DerivativeInstrument) SetDerivativeListMethod(v int) { m.Derivative func (m *DerivativeInstrument) SetDerivativeCapPrice(v float64) { m.DerivativeCapPrice = &v } func (m *DerivativeInstrument) SetDerivativeFloorPrice(v float64) { m.DerivativeFloorPrice = &v } func (m *DerivativeInstrument) SetDerivativePutOrCall(v int) { m.DerivativePutOrCall = &v } -func (m *DerivativeInstrument) SetDerivativeSecurityXMLLen(v int) { m.DerivativeSecurityXMLLen = &v } -func (m *DerivativeInstrument) SetDerivativeSecurityXML(v string) { m.DerivativeSecurityXML = &v } -func (m *DerivativeInstrument) SetDerivativeSecurityXMLSchema(v string) { - m.DerivativeSecurityXMLSchema = &v -} func (m *DerivativeInstrument) SetDerivativeContractMultiplierUnit(v int) { m.DerivativeContractMultiplierUnit = &v } diff --git a/fix50sp2/derivativesecuritydefinition/DerivativeSecurityDefinition.go b/fix50sp2/derivativesecuritydefinition/DerivativeSecurityDefinition.go index 8328be9b9..3b123429a 100644 --- a/fix50sp2/derivativesecuritydefinition/DerivativeSecurityDefinition.go +++ b/fix50sp2/derivativesecuritydefinition/DerivativeSecurityDefinition.go @@ -1,363 +1,17 @@ package derivativesecuritydefinition import ( - "github.com/quickfixgo/quickfix/fix50sp2/derivativeinstrumentpartysubidsgrp" - "github.com/quickfixgo/quickfix/fix50sp2/securitytradingrules" - "github.com/quickfixgo/quickfix/fix50sp2/strikerules" - "time" + "github.com/quickfixgo/quickfix/fix50sp2/derivativeinstrument" + "github.com/quickfixgo/quickfix/fix50sp2/derivativeinstrumentattribute" + "github.com/quickfixgo/quickfix/fix50sp2/marketsegmentgrp" ) -//NoDerivativeSecurityAltID is a repeating group in DerivativeSecurityDefinition -type NoDerivativeSecurityAltID struct { - //DerivativeSecurityAltID is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltID *string `fix:"1219"` - //DerivativeSecurityAltIDSource is a non-required field for NoDerivativeSecurityAltID. - DerivativeSecurityAltIDSource *string `fix:"1220"` -} - -//NoDerivativeEvents is a repeating group in DerivativeSecurityDefinition -type NoDerivativeEvents struct { - //DerivativeEventType is a non-required field for NoDerivativeEvents. - DerivativeEventType *int `fix:"1287"` - //DerivativeEventDate is a non-required field for NoDerivativeEvents. - DerivativeEventDate *string `fix:"1288"` - //DerivativeEventTime is a non-required field for NoDerivativeEvents. - DerivativeEventTime *time.Time `fix:"1289"` - //DerivativeEventPx is a non-required field for NoDerivativeEvents. - DerivativeEventPx *float64 `fix:"1290"` - //DerivativeEventText is a non-required field for NoDerivativeEvents. - DerivativeEventText *string `fix:"1291"` -} - -//NoDerivativeInstrumentParties is a repeating group in DerivativeSecurityDefinition -type NoDerivativeInstrumentParties struct { - //DerivativeInstrumentPartyID is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyID *string `fix:"1293"` - //DerivativeInstrumentPartyIDSource is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyIDSource *string `fix:"1294"` - //DerivativeInstrumentPartyRole is a non-required field for NoDerivativeInstrumentParties. - DerivativeInstrumentPartyRole *int `fix:"1295"` - //DerivativeInstrumentPartySubIDsGrp Component - derivativeinstrumentpartysubidsgrp.DerivativeInstrumentPartySubIDsGrp -} - -//NoDerivativeInstrAttrib is a repeating group in DerivativeSecurityDefinition -type NoDerivativeInstrAttrib struct { - //DerivativeInstrAttribType is a non-required field for NoDerivativeInstrAttrib. - DerivativeInstrAttribType *int `fix:"1313"` - //DerivativeInstrAttribValue is a non-required field for NoDerivativeInstrAttrib. - DerivativeInstrAttribValue *string `fix:"1314"` -} - -//NoMarketSegments is a repeating group in DerivativeSecurityDefinition -type NoMarketSegments struct { - //MarketID is a non-required field for NoMarketSegments. - MarketID *string `fix:"1301"` - //MarketSegmentID is a non-required field for NoMarketSegments. - MarketSegmentID *string `fix:"1300"` - //SecurityTradingRules Component - securitytradingrules.SecurityTradingRules - //StrikeRules Component - strikerules.StrikeRules -} - //DerivativeSecurityDefinition is a fix50sp2 Component type DerivativeSecurityDefinition struct { - //DerivativeSymbol is a non-required field for DerivativeSecurityDefinition. - DerivativeSymbol *string `fix:"1214"` - //DerivativeSymbolSfx is a non-required field for DerivativeSecurityDefinition. - DerivativeSymbolSfx *string `fix:"1215"` - //DerivativeSecurityID is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityID *string `fix:"1216"` - //DerivativeSecurityIDSource is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityIDSource *string `fix:"1217"` - //NoDerivativeSecurityAltID is a non-required field for DerivativeSecurityDefinition. - NoDerivativeSecurityAltID []NoDerivativeSecurityAltID `fix:"1218,omitempty"` - //DerivativeProduct is a non-required field for DerivativeSecurityDefinition. - DerivativeProduct *int `fix:"1246"` - //DerivativeProductComplex is a non-required field for DerivativeSecurityDefinition. - DerivativeProductComplex *string `fix:"1228"` - //DerivFlexProductEligibilityIndicator is a non-required field for DerivativeSecurityDefinition. - DerivFlexProductEligibilityIndicator *bool `fix:"1243"` - //DerivativeSecurityGroup is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityGroup *string `fix:"1247"` - //DerivativeCFICode is a non-required field for DerivativeSecurityDefinition. - DerivativeCFICode *string `fix:"1248"` - //DerivativeSecurityType is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityType *string `fix:"1249"` - //DerivativeSecuritySubType is a non-required field for DerivativeSecurityDefinition. - DerivativeSecuritySubType *string `fix:"1250"` - //DerivativeMaturityMonthYear is a non-required field for DerivativeSecurityDefinition. - DerivativeMaturityMonthYear *string `fix:"1251"` - //DerivativeMaturityDate is a non-required field for DerivativeSecurityDefinition. - DerivativeMaturityDate *string `fix:"1252"` - //DerivativeMaturityTime is a non-required field for DerivativeSecurityDefinition. - DerivativeMaturityTime *string `fix:"1253"` - //DerivativeSettleOnOpenFlag is a non-required field for DerivativeSecurityDefinition. - DerivativeSettleOnOpenFlag *string `fix:"1254"` - //DerivativeInstrmtAssignmentMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeInstrmtAssignmentMethod *string `fix:"1255"` - //DerivativeSecurityStatus is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityStatus *string `fix:"1256"` - //DerivativeIssueDate is a non-required field for DerivativeSecurityDefinition. - DerivativeIssueDate *string `fix:"1276"` - //DerivativeInstrRegistry is a non-required field for DerivativeSecurityDefinition. - DerivativeInstrRegistry *string `fix:"1257"` - //DerivativeCountryOfIssue is a non-required field for DerivativeSecurityDefinition. - DerivativeCountryOfIssue *string `fix:"1258"` - //DerivativeStateOrProvinceOfIssue is a non-required field for DerivativeSecurityDefinition. - DerivativeStateOrProvinceOfIssue *string `fix:"1259"` - //DerivativeStrikePrice is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikePrice *float64 `fix:"1261"` - //DerivativeLocaleOfIssue is a non-required field for DerivativeSecurityDefinition. - DerivativeLocaleOfIssue *string `fix:"1260"` - //DerivativeStrikeCurrency is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikeCurrency *string `fix:"1262"` - //DerivativeStrikeMultiplier is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikeMultiplier *float64 `fix:"1263"` - //DerivativeStrikeValue is a non-required field for DerivativeSecurityDefinition. - DerivativeStrikeValue *float64 `fix:"1264"` - //DerivativeOptAttribute is a non-required field for DerivativeSecurityDefinition. - DerivativeOptAttribute *string `fix:"1265"` - //DerivativeContractMultiplier is a non-required field for DerivativeSecurityDefinition. - DerivativeContractMultiplier *float64 `fix:"1266"` - //DerivativeMinPriceIncrement is a non-required field for DerivativeSecurityDefinition. - DerivativeMinPriceIncrement *float64 `fix:"1267"` - //DerivativeMinPriceIncrementAmount is a non-required field for DerivativeSecurityDefinition. - DerivativeMinPriceIncrementAmount *float64 `fix:"1268"` - //DerivativeUnitOfMeasure is a non-required field for DerivativeSecurityDefinition. - DerivativeUnitOfMeasure *string `fix:"1269"` - //DerivativeUnitOfMeasureQty is a non-required field for DerivativeSecurityDefinition. - DerivativeUnitOfMeasureQty *float64 `fix:"1270"` - //DerivativePriceUnitOfMeasure is a non-required field for DerivativeSecurityDefinition. - DerivativePriceUnitOfMeasure *string `fix:"1315"` - //DerivativePriceUnitOfMeasureQty is a non-required field for DerivativeSecurityDefinition. - DerivativePriceUnitOfMeasureQty *float64 `fix:"1316"` - //DerivativeExerciseStyle is a non-required field for DerivativeSecurityDefinition. - DerivativeExerciseStyle *string `fix:"1299"` - //DerivativeOptPayAmount is a non-required field for DerivativeSecurityDefinition. - DerivativeOptPayAmount *float64 `fix:"1225"` - //DerivativeTimeUnit is a non-required field for DerivativeSecurityDefinition. - DerivativeTimeUnit *string `fix:"1271"` - //DerivativeSecurityExchange is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityExchange *string `fix:"1272"` - //DerivativePositionLimit is a non-required field for DerivativeSecurityDefinition. - DerivativePositionLimit *int `fix:"1273"` - //DerivativeNTPositionLimit is a non-required field for DerivativeSecurityDefinition. - DerivativeNTPositionLimit *int `fix:"1274"` - //DerivativeIssuer is a non-required field for DerivativeSecurityDefinition. - DerivativeIssuer *string `fix:"1275"` - //DerivativeEncodedIssuerLen is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedIssuerLen *int `fix:"1277"` - //DerivativeEncodedIssuer is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedIssuer *string `fix:"1278"` - //DerivativeSecurityDesc is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityDesc *string `fix:"1279"` - //DerivativeEncodedSecurityDescLen is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedSecurityDescLen *int `fix:"1280"` - //DerivativeEncodedSecurityDesc is a non-required field for DerivativeSecurityDefinition. - DerivativeEncodedSecurityDesc *string `fix:"1281"` - //DerivativeContractSettlMonth is a non-required field for DerivativeSecurityDefinition. - DerivativeContractSettlMonth *string `fix:"1285"` - //NoDerivativeEvents is a non-required field for DerivativeSecurityDefinition. - NoDerivativeEvents []NoDerivativeEvents `fix:"1286,omitempty"` - //NoDerivativeInstrumentParties is a non-required field for DerivativeSecurityDefinition. - NoDerivativeInstrumentParties []NoDerivativeInstrumentParties `fix:"1292,omitempty"` - //DerivativeSettlMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeSettlMethod *string `fix:"1317"` - //DerivativePriceQuoteMethod is a non-required field for DerivativeSecurityDefinition. - DerivativePriceQuoteMethod *string `fix:"1318"` - //DerivativeValuationMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeValuationMethod *string `fix:"1319"` - //DerivativeListMethod is a non-required field for DerivativeSecurityDefinition. - DerivativeListMethod *int `fix:"1320"` - //DerivativeCapPrice is a non-required field for DerivativeSecurityDefinition. - DerivativeCapPrice *float64 `fix:"1321"` - //DerivativeFloorPrice is a non-required field for DerivativeSecurityDefinition. - DerivativeFloorPrice *float64 `fix:"1322"` - //DerivativePutOrCall is a non-required field for DerivativeSecurityDefinition. - DerivativePutOrCall *int `fix:"1323"` - //DerivativeSecurityXMLLen is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityXMLLen *int `fix:"1282"` - //DerivativeSecurityXML is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityXML *string `fix:"1283"` - //DerivativeSecurityXMLSchema is a non-required field for DerivativeSecurityDefinition. - DerivativeSecurityXMLSchema *string `fix:"1284"` - //DerivativeContractMultiplierUnit is a non-required field for DerivativeSecurityDefinition. - DerivativeContractMultiplierUnit *int `fix:"1438"` - //DerivativeFlowScheduleType is a non-required field for DerivativeSecurityDefinition. - DerivativeFlowScheduleType *int `fix:"1442"` - //NoDerivativeInstrAttrib is a non-required field for DerivativeSecurityDefinition. - NoDerivativeInstrAttrib []NoDerivativeInstrAttrib `fix:"1311,omitempty"` - //NoMarketSegments is a non-required field for DerivativeSecurityDefinition. - NoMarketSegments []NoMarketSegments `fix:"1310,omitempty"` -} - -func (m *DerivativeSecurityDefinition) SetDerivativeSymbol(v string) { m.DerivativeSymbol = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSymbolSfx(v string) { m.DerivativeSymbolSfx = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityID(v string) { m.DerivativeSecurityID = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityIDSource(v string) { - m.DerivativeSecurityIDSource = &v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeSecurityAltID(v []NoDerivativeSecurityAltID) { - m.NoDerivativeSecurityAltID = v -} -func (m *DerivativeSecurityDefinition) SetDerivativeProduct(v int) { m.DerivativeProduct = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeProductComplex(v string) { - m.DerivativeProductComplex = &v -} -func (m *DerivativeSecurityDefinition) SetDerivFlexProductEligibilityIndicator(v bool) { - m.DerivFlexProductEligibilityIndicator = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityGroup(v string) { - m.DerivativeSecurityGroup = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeCFICode(v string) { m.DerivativeCFICode = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityType(v string) { - m.DerivativeSecurityType = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecuritySubType(v string) { - m.DerivativeSecuritySubType = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMaturityMonthYear(v string) { - m.DerivativeMaturityMonthYear = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMaturityDate(v string) { - m.DerivativeMaturityDate = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMaturityTime(v string) { - m.DerivativeMaturityTime = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSettleOnOpenFlag(v string) { - m.DerivativeSettleOnOpenFlag = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeInstrmtAssignmentMethod(v string) { - m.DerivativeInstrmtAssignmentMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityStatus(v string) { - m.DerivativeSecurityStatus = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeIssueDate(v string) { m.DerivativeIssueDate = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeInstrRegistry(v string) { - m.DerivativeInstrRegistry = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeCountryOfIssue(v string) { - m.DerivativeCountryOfIssue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStateOrProvinceOfIssue(v string) { - m.DerivativeStateOrProvinceOfIssue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikePrice(v float64) { - m.DerivativeStrikePrice = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeLocaleOfIssue(v string) { - m.DerivativeLocaleOfIssue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikeCurrency(v string) { - m.DerivativeStrikeCurrency = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikeMultiplier(v float64) { - m.DerivativeStrikeMultiplier = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeStrikeValue(v float64) { - m.DerivativeStrikeValue = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeOptAttribute(v string) { - m.DerivativeOptAttribute = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeContractMultiplier(v float64) { - m.DerivativeContractMultiplier = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMinPriceIncrement(v float64) { - m.DerivativeMinPriceIncrement = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeMinPriceIncrementAmount(v float64) { - m.DerivativeMinPriceIncrementAmount = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeUnitOfMeasure(v string) { - m.DerivativeUnitOfMeasure = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeUnitOfMeasureQty(v float64) { - m.DerivativeUnitOfMeasureQty = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePriceUnitOfMeasure(v string) { - m.DerivativePriceUnitOfMeasure = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePriceUnitOfMeasureQty(v float64) { - m.DerivativePriceUnitOfMeasureQty = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeExerciseStyle(v string) { - m.DerivativeExerciseStyle = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeOptPayAmount(v float64) { - m.DerivativeOptPayAmount = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeTimeUnit(v string) { m.DerivativeTimeUnit = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityExchange(v string) { - m.DerivativeSecurityExchange = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePositionLimit(v int) { - m.DerivativePositionLimit = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeNTPositionLimit(v int) { - m.DerivativeNTPositionLimit = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeIssuer(v string) { m.DerivativeIssuer = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedIssuerLen(v int) { - m.DerivativeEncodedIssuerLen = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedIssuer(v string) { - m.DerivativeEncodedIssuer = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityDesc(v string) { - m.DerivativeSecurityDesc = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedSecurityDescLen(v int) { - m.DerivativeEncodedSecurityDescLen = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeEncodedSecurityDesc(v string) { - m.DerivativeEncodedSecurityDesc = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeContractSettlMonth(v string) { - m.DerivativeContractSettlMonth = &v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeEvents(v []NoDerivativeEvents) { - m.NoDerivativeEvents = v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeInstrumentParties(v []NoDerivativeInstrumentParties) { - m.NoDerivativeInstrumentParties = v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSettlMethod(v string) { - m.DerivativeSettlMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativePriceQuoteMethod(v string) { - m.DerivativePriceQuoteMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeValuationMethod(v string) { - m.DerivativeValuationMethod = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeListMethod(v int) { m.DerivativeListMethod = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeCapPrice(v float64) { m.DerivativeCapPrice = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeFloorPrice(v float64) { m.DerivativeFloorPrice = &v } -func (m *DerivativeSecurityDefinition) SetDerivativePutOrCall(v int) { m.DerivativePutOrCall = &v } -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityXMLLen(v int) { - m.DerivativeSecurityXMLLen = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityXML(v string) { - m.DerivativeSecurityXML = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeSecurityXMLSchema(v string) { - m.DerivativeSecurityXMLSchema = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeContractMultiplierUnit(v int) { - m.DerivativeContractMultiplierUnit = &v -} -func (m *DerivativeSecurityDefinition) SetDerivativeFlowScheduleType(v int) { - m.DerivativeFlowScheduleType = &v -} -func (m *DerivativeSecurityDefinition) SetNoDerivativeInstrAttrib(v []NoDerivativeInstrAttrib) { - m.NoDerivativeInstrAttrib = v -} -func (m *DerivativeSecurityDefinition) SetNoMarketSegments(v []NoMarketSegments) { - m.NoMarketSegments = v + //DerivativeInstrument Component + derivativeinstrument.DerivativeInstrument + //DerivativeInstrumentAttribute Component + derivativeinstrumentattribute.DerivativeInstrumentAttribute + //MarketSegmentGrp Component + marketsegmentgrp.MarketSegmentGrp } diff --git a/fix50sp2/instrument/Instrument.go b/fix50sp2/instrument/Instrument.go index 815a6f941..836e84d4a 100644 --- a/fix50sp2/instrument/Instrument.go +++ b/fix50sp2/instrument/Instrument.go @@ -1,65 +1,13 @@ package instrument import ( - "github.com/quickfixgo/quickfix/fix50sp2/complexeventdates" - "github.com/quickfixgo/quickfix/fix50sp2/instrumentptyssubgrp" - "time" + "github.com/quickfixgo/quickfix/fix50sp2/complexevents" + "github.com/quickfixgo/quickfix/fix50sp2/evntgrp" + "github.com/quickfixgo/quickfix/fix50sp2/instrumentparties" + "github.com/quickfixgo/quickfix/fix50sp2/secaltidgrp" + "github.com/quickfixgo/quickfix/fix50sp2/securityxml" ) -//NoSecurityAltID is a repeating group in Instrument -type NoSecurityAltID struct { - //SecurityAltID is a non-required field for NoSecurityAltID. - SecurityAltID *string `fix:"455"` - //SecurityAltIDSource is a non-required field for NoSecurityAltID. - SecurityAltIDSource *string `fix:"456"` -} - -//NoEvents is a repeating group in Instrument -type NoEvents struct { - //EventType is a non-required field for NoEvents. - EventType *int `fix:"865"` - //EventDate is a non-required field for NoEvents. - EventDate *string `fix:"866"` - //EventPx is a non-required field for NoEvents. - EventPx *float64 `fix:"867"` - //EventText is a non-required field for NoEvents. - EventText *string `fix:"868"` - //EventTime is a non-required field for NoEvents. - EventTime *time.Time `fix:"1145"` -} - -//NoInstrumentParties is a repeating group in Instrument -type NoInstrumentParties struct { - //InstrumentPartyID is a non-required field for NoInstrumentParties. - InstrumentPartyID *string `fix:"1019"` - //InstrumentPartyIDSource is a non-required field for NoInstrumentParties. - InstrumentPartyIDSource *string `fix:"1050"` - //InstrumentPartyRole is a non-required field for NoInstrumentParties. - InstrumentPartyRole *int `fix:"1051"` - //InstrumentPtysSubGrp Component - instrumentptyssubgrp.InstrumentPtysSubGrp -} - -//NoComplexEvents is a repeating group in Instrument -type NoComplexEvents struct { - //ComplexEventType is a non-required field for NoComplexEvents. - ComplexEventType *int `fix:"1484"` - //ComplexOptPayoutAmount is a non-required field for NoComplexEvents. - ComplexOptPayoutAmount *float64 `fix:"1485"` - //ComplexEventPrice is a non-required field for NoComplexEvents. - ComplexEventPrice *float64 `fix:"1486"` - //ComplexEventPriceBoundaryMethod is a non-required field for NoComplexEvents. - ComplexEventPriceBoundaryMethod *int `fix:"1487"` - //ComplexEventPriceBoundaryPrecision is a non-required field for NoComplexEvents. - ComplexEventPriceBoundaryPrecision *float64 `fix:"1488"` - //ComplexEventPriceTimeType is a non-required field for NoComplexEvents. - ComplexEventPriceTimeType *int `fix:"1489"` - //ComplexEventCondition is a non-required field for NoComplexEvents. - ComplexEventCondition *int `fix:"1490"` - //ComplexEventDates Component - complexeventdates.ComplexEventDates -} - //Instrument is a fix50sp2 Component type Instrument struct { //Symbol is a non-required field for Instrument. @@ -70,8 +18,8 @@ type Instrument struct { SecurityID *string `fix:"48"` //SecurityIDSource is a non-required field for Instrument. SecurityIDSource *string `fix:"22"` - //NoSecurityAltID is a non-required field for Instrument. - NoSecurityAltID []NoSecurityAltID `fix:"454,omitempty"` + //SecAltIDGrp Component + secaltidgrp.SecAltIDGrp //Product is a non-required field for Instrument. Product *int `fix:"460"` //CFICode is a non-required field for Instrument. @@ -140,8 +88,8 @@ type Instrument struct { CPProgram *int `fix:"875"` //CPRegType is a non-required field for Instrument. CPRegType *string `fix:"876"` - //NoEvents is a non-required field for Instrument. - NoEvents []NoEvents `fix:"864,omitempty"` + //EvntGrp Component + evntgrp.EvntGrp //DatedDate is a non-required field for Instrument. DatedDate *string `fix:"873"` //InterestAccrualDate is a non-required field for Instrument. @@ -162,8 +110,8 @@ type Instrument struct { PositionLimit *int `fix:"970"` //NTPositionLimit is a non-required field for Instrument. NTPositionLimit *int `fix:"971"` - //NoInstrumentParties is a non-required field for Instrument. - NoInstrumentParties []NoInstrumentParties `fix:"1018,omitempty"` + //InstrumentParties Component + instrumentparties.InstrumentParties //UnitOfMeasure is a non-required field for Instrument. UnitOfMeasure *string `fix:"996"` //TimeUnit is a non-required field for Instrument. @@ -176,12 +124,8 @@ type Instrument struct { MinPriceIncrementAmount *float64 `fix:"1146"` //UnitOfMeasureQty is a non-required field for Instrument. UnitOfMeasureQty *float64 `fix:"1147"` - //SecurityXMLLen is a non-required field for Instrument. - SecurityXMLLen *int `fix:"1184"` - //SecurityXML is a non-required field for Instrument. - SecurityXML *string `fix:"1185"` - //SecurityXMLSchema is a non-required field for Instrument. - SecurityXMLSchema *string `fix:"1186"` + //SecurityXML Component + securityxml.SecurityXML //ProductComplex is a non-required field for Instrument. ProductComplex *string `fix:"1227"` //PriceUnitOfMeasure is a non-required field for Instrument. @@ -236,82 +180,76 @@ type Instrument struct { UnderlyingPriceDeterminationMethod *int `fix:"1481"` //OptPayoutType is a non-required field for Instrument. OptPayoutType *int `fix:"1482"` - //NoComplexEvents is a non-required field for Instrument. - NoComplexEvents []NoComplexEvents `fix:"1483,omitempty"` + //ComplexEvents Component + complexevents.ComplexEvents } -func (m *Instrument) SetSymbol(v string) { m.Symbol = &v } -func (m *Instrument) SetSymbolSfx(v string) { m.SymbolSfx = &v } -func (m *Instrument) SetSecurityID(v string) { m.SecurityID = &v } -func (m *Instrument) SetSecurityIDSource(v string) { m.SecurityIDSource = &v } -func (m *Instrument) SetNoSecurityAltID(v []NoSecurityAltID) { m.NoSecurityAltID = v } -func (m *Instrument) SetProduct(v int) { m.Product = &v } -func (m *Instrument) SetCFICode(v string) { m.CFICode = &v } -func (m *Instrument) SetSecurityType(v string) { m.SecurityType = &v } -func (m *Instrument) SetSecuritySubType(v string) { m.SecuritySubType = &v } -func (m *Instrument) SetMaturityMonthYear(v string) { m.MaturityMonthYear = &v } -func (m *Instrument) SetMaturityDate(v string) { m.MaturityDate = &v } -func (m *Instrument) SetCouponPaymentDate(v string) { m.CouponPaymentDate = &v } -func (m *Instrument) SetIssueDate(v string) { m.IssueDate = &v } -func (m *Instrument) SetRepoCollateralSecurityType(v int) { m.RepoCollateralSecurityType = &v } -func (m *Instrument) SetRepurchaseTerm(v int) { m.RepurchaseTerm = &v } -func (m *Instrument) SetRepurchaseRate(v float64) { m.RepurchaseRate = &v } -func (m *Instrument) SetFactor(v float64) { m.Factor = &v } -func (m *Instrument) SetCreditRating(v string) { m.CreditRating = &v } -func (m *Instrument) SetInstrRegistry(v string) { m.InstrRegistry = &v } -func (m *Instrument) SetCountryOfIssue(v string) { m.CountryOfIssue = &v } -func (m *Instrument) SetStateOrProvinceOfIssue(v string) { m.StateOrProvinceOfIssue = &v } -func (m *Instrument) SetLocaleOfIssue(v string) { m.LocaleOfIssue = &v } -func (m *Instrument) SetRedemptionDate(v string) { m.RedemptionDate = &v } -func (m *Instrument) SetStrikePrice(v float64) { m.StrikePrice = &v } -func (m *Instrument) SetStrikeCurrency(v string) { m.StrikeCurrency = &v } -func (m *Instrument) SetOptAttribute(v string) { m.OptAttribute = &v } -func (m *Instrument) SetContractMultiplier(v float64) { m.ContractMultiplier = &v } -func (m *Instrument) SetCouponRate(v float64) { m.CouponRate = &v } -func (m *Instrument) SetSecurityExchange(v string) { m.SecurityExchange = &v } -func (m *Instrument) SetIssuer(v string) { m.Issuer = &v } -func (m *Instrument) SetEncodedIssuerLen(v int) { m.EncodedIssuerLen = &v } -func (m *Instrument) SetEncodedIssuer(v string) { m.EncodedIssuer = &v } -func (m *Instrument) SetSecurityDesc(v string) { m.SecurityDesc = &v } -func (m *Instrument) SetEncodedSecurityDescLen(v int) { m.EncodedSecurityDescLen = &v } -func (m *Instrument) SetEncodedSecurityDesc(v string) { m.EncodedSecurityDesc = &v } -func (m *Instrument) SetPool(v string) { m.Pool = &v } -func (m *Instrument) SetContractSettlMonth(v string) { m.ContractSettlMonth = &v } -func (m *Instrument) SetCPProgram(v int) { m.CPProgram = &v } -func (m *Instrument) SetCPRegType(v string) { m.CPRegType = &v } -func (m *Instrument) SetNoEvents(v []NoEvents) { m.NoEvents = v } -func (m *Instrument) SetDatedDate(v string) { m.DatedDate = &v } -func (m *Instrument) SetInterestAccrualDate(v string) { m.InterestAccrualDate = &v } -func (m *Instrument) SetSecurityStatus(v string) { m.SecurityStatus = &v } -func (m *Instrument) SetSettleOnOpenFlag(v string) { m.SettleOnOpenFlag = &v } -func (m *Instrument) SetInstrmtAssignmentMethod(v string) { m.InstrmtAssignmentMethod = &v } -func (m *Instrument) SetStrikeMultiplier(v float64) { m.StrikeMultiplier = &v } -func (m *Instrument) SetStrikeValue(v float64) { m.StrikeValue = &v } -func (m *Instrument) SetMinPriceIncrement(v float64) { m.MinPriceIncrement = &v } -func (m *Instrument) SetPositionLimit(v int) { m.PositionLimit = &v } -func (m *Instrument) SetNTPositionLimit(v int) { m.NTPositionLimit = &v } -func (m *Instrument) SetNoInstrumentParties(v []NoInstrumentParties) { m.NoInstrumentParties = v } -func (m *Instrument) SetUnitOfMeasure(v string) { m.UnitOfMeasure = &v } -func (m *Instrument) SetTimeUnit(v string) { m.TimeUnit = &v } -func (m *Instrument) SetMaturityTime(v string) { m.MaturityTime = &v } -func (m *Instrument) SetSecurityGroup(v string) { m.SecurityGroup = &v } -func (m *Instrument) SetMinPriceIncrementAmount(v float64) { m.MinPriceIncrementAmount = &v } -func (m *Instrument) SetUnitOfMeasureQty(v float64) { m.UnitOfMeasureQty = &v } -func (m *Instrument) SetSecurityXMLLen(v int) { m.SecurityXMLLen = &v } -func (m *Instrument) SetSecurityXML(v string) { m.SecurityXML = &v } -func (m *Instrument) SetSecurityXMLSchema(v string) { m.SecurityXMLSchema = &v } -func (m *Instrument) SetProductComplex(v string) { m.ProductComplex = &v } -func (m *Instrument) SetPriceUnitOfMeasure(v string) { m.PriceUnitOfMeasure = &v } -func (m *Instrument) SetPriceUnitOfMeasureQty(v float64) { m.PriceUnitOfMeasureQty = &v } -func (m *Instrument) SetSettlMethod(v string) { m.SettlMethod = &v } -func (m *Instrument) SetExerciseStyle(v int) { m.ExerciseStyle = &v } -func (m *Instrument) SetOptPayoutAmount(v float64) { m.OptPayoutAmount = &v } -func (m *Instrument) SetPriceQuoteMethod(v string) { m.PriceQuoteMethod = &v } -func (m *Instrument) SetListMethod(v int) { m.ListMethod = &v } -func (m *Instrument) SetCapPrice(v float64) { m.CapPrice = &v } -func (m *Instrument) SetFloorPrice(v float64) { m.FloorPrice = &v } -func (m *Instrument) SetPutOrCall(v int) { m.PutOrCall = &v } -func (m *Instrument) SetFlexibleIndicator(v bool) { m.FlexibleIndicator = &v } +func (m *Instrument) SetSymbol(v string) { m.Symbol = &v } +func (m *Instrument) SetSymbolSfx(v string) { m.SymbolSfx = &v } +func (m *Instrument) SetSecurityID(v string) { m.SecurityID = &v } +func (m *Instrument) SetSecurityIDSource(v string) { m.SecurityIDSource = &v } +func (m *Instrument) SetProduct(v int) { m.Product = &v } +func (m *Instrument) SetCFICode(v string) { m.CFICode = &v } +func (m *Instrument) SetSecurityType(v string) { m.SecurityType = &v } +func (m *Instrument) SetSecuritySubType(v string) { m.SecuritySubType = &v } +func (m *Instrument) SetMaturityMonthYear(v string) { m.MaturityMonthYear = &v } +func (m *Instrument) SetMaturityDate(v string) { m.MaturityDate = &v } +func (m *Instrument) SetCouponPaymentDate(v string) { m.CouponPaymentDate = &v } +func (m *Instrument) SetIssueDate(v string) { m.IssueDate = &v } +func (m *Instrument) SetRepoCollateralSecurityType(v int) { m.RepoCollateralSecurityType = &v } +func (m *Instrument) SetRepurchaseTerm(v int) { m.RepurchaseTerm = &v } +func (m *Instrument) SetRepurchaseRate(v float64) { m.RepurchaseRate = &v } +func (m *Instrument) SetFactor(v float64) { m.Factor = &v } +func (m *Instrument) SetCreditRating(v string) { m.CreditRating = &v } +func (m *Instrument) SetInstrRegistry(v string) { m.InstrRegistry = &v } +func (m *Instrument) SetCountryOfIssue(v string) { m.CountryOfIssue = &v } +func (m *Instrument) SetStateOrProvinceOfIssue(v string) { m.StateOrProvinceOfIssue = &v } +func (m *Instrument) SetLocaleOfIssue(v string) { m.LocaleOfIssue = &v } +func (m *Instrument) SetRedemptionDate(v string) { m.RedemptionDate = &v } +func (m *Instrument) SetStrikePrice(v float64) { m.StrikePrice = &v } +func (m *Instrument) SetStrikeCurrency(v string) { m.StrikeCurrency = &v } +func (m *Instrument) SetOptAttribute(v string) { m.OptAttribute = &v } +func (m *Instrument) SetContractMultiplier(v float64) { m.ContractMultiplier = &v } +func (m *Instrument) SetCouponRate(v float64) { m.CouponRate = &v } +func (m *Instrument) SetSecurityExchange(v string) { m.SecurityExchange = &v } +func (m *Instrument) SetIssuer(v string) { m.Issuer = &v } +func (m *Instrument) SetEncodedIssuerLen(v int) { m.EncodedIssuerLen = &v } +func (m *Instrument) SetEncodedIssuer(v string) { m.EncodedIssuer = &v } +func (m *Instrument) SetSecurityDesc(v string) { m.SecurityDesc = &v } +func (m *Instrument) SetEncodedSecurityDescLen(v int) { m.EncodedSecurityDescLen = &v } +func (m *Instrument) SetEncodedSecurityDesc(v string) { m.EncodedSecurityDesc = &v } +func (m *Instrument) SetPool(v string) { m.Pool = &v } +func (m *Instrument) SetContractSettlMonth(v string) { m.ContractSettlMonth = &v } +func (m *Instrument) SetCPProgram(v int) { m.CPProgram = &v } +func (m *Instrument) SetCPRegType(v string) { m.CPRegType = &v } +func (m *Instrument) SetDatedDate(v string) { m.DatedDate = &v } +func (m *Instrument) SetInterestAccrualDate(v string) { m.InterestAccrualDate = &v } +func (m *Instrument) SetSecurityStatus(v string) { m.SecurityStatus = &v } +func (m *Instrument) SetSettleOnOpenFlag(v string) { m.SettleOnOpenFlag = &v } +func (m *Instrument) SetInstrmtAssignmentMethod(v string) { m.InstrmtAssignmentMethod = &v } +func (m *Instrument) SetStrikeMultiplier(v float64) { m.StrikeMultiplier = &v } +func (m *Instrument) SetStrikeValue(v float64) { m.StrikeValue = &v } +func (m *Instrument) SetMinPriceIncrement(v float64) { m.MinPriceIncrement = &v } +func (m *Instrument) SetPositionLimit(v int) { m.PositionLimit = &v } +func (m *Instrument) SetNTPositionLimit(v int) { m.NTPositionLimit = &v } +func (m *Instrument) SetUnitOfMeasure(v string) { m.UnitOfMeasure = &v } +func (m *Instrument) SetTimeUnit(v string) { m.TimeUnit = &v } +func (m *Instrument) SetMaturityTime(v string) { m.MaturityTime = &v } +func (m *Instrument) SetSecurityGroup(v string) { m.SecurityGroup = &v } +func (m *Instrument) SetMinPriceIncrementAmount(v float64) { m.MinPriceIncrementAmount = &v } +func (m *Instrument) SetUnitOfMeasureQty(v float64) { m.UnitOfMeasureQty = &v } +func (m *Instrument) SetProductComplex(v string) { m.ProductComplex = &v } +func (m *Instrument) SetPriceUnitOfMeasure(v string) { m.PriceUnitOfMeasure = &v } +func (m *Instrument) SetPriceUnitOfMeasureQty(v float64) { m.PriceUnitOfMeasureQty = &v } +func (m *Instrument) SetSettlMethod(v string) { m.SettlMethod = &v } +func (m *Instrument) SetExerciseStyle(v int) { m.ExerciseStyle = &v } +func (m *Instrument) SetOptPayoutAmount(v float64) { m.OptPayoutAmount = &v } +func (m *Instrument) SetPriceQuoteMethod(v string) { m.PriceQuoteMethod = &v } +func (m *Instrument) SetListMethod(v int) { m.ListMethod = &v } +func (m *Instrument) SetCapPrice(v float64) { m.CapPrice = &v } +func (m *Instrument) SetFloorPrice(v float64) { m.FloorPrice = &v } +func (m *Instrument) SetPutOrCall(v int) { m.PutOrCall = &v } +func (m *Instrument) SetFlexibleIndicator(v bool) { m.FlexibleIndicator = &v } func (m *Instrument) SetFlexProductEligibilityIndicator(v bool) { m.FlexProductEligibilityIndicator = &v } @@ -332,5 +270,4 @@ func (m *Instrument) SetStrikePriceBoundaryPrecision(v float64) { m.StrikePriceB func (m *Instrument) SetUnderlyingPriceDeterminationMethod(v int) { m.UnderlyingPriceDeterminationMethod = &v } -func (m *Instrument) SetOptPayoutType(v int) { m.OptPayoutType = &v } -func (m *Instrument) SetNoComplexEvents(v []NoComplexEvents) { m.NoComplexEvents = v } +func (m *Instrument) SetOptPayoutType(v int) { m.OptPayoutType = &v } diff --git a/fix50sp2/instrumentextension/InstrumentExtension.go b/fix50sp2/instrumentextension/InstrumentExtension.go index df801d46b..796100e38 100644 --- a/fix50sp2/instrumentextension/InstrumentExtension.go +++ b/fix50sp2/instrumentextension/InstrumentExtension.go @@ -1,12 +1,8 @@ package instrumentextension -//NoInstrAttrib is a repeating group in InstrumentExtension -type NoInstrAttrib struct { - //InstrAttribType is a non-required field for NoInstrAttrib. - InstrAttribType *int `fix:"871"` - //InstrAttribValue is a non-required field for NoInstrAttrib. - InstrAttribValue *string `fix:"872"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp2/attrbgrp" +) //InstrumentExtension is a fix50sp2 Component type InstrumentExtension struct { @@ -14,10 +10,9 @@ type InstrumentExtension struct { DeliveryForm *int `fix:"668"` //PctAtRisk is a non-required field for InstrumentExtension. PctAtRisk *float64 `fix:"869"` - //NoInstrAttrib is a non-required field for InstrumentExtension. - NoInstrAttrib []NoInstrAttrib `fix:"870,omitempty"` + //AttrbGrp Component + attrbgrp.AttrbGrp } -func (m *InstrumentExtension) SetDeliveryForm(v int) { m.DeliveryForm = &v } -func (m *InstrumentExtension) SetPctAtRisk(v float64) { m.PctAtRisk = &v } -func (m *InstrumentExtension) SetNoInstrAttrib(v []NoInstrAttrib) { m.NoInstrAttrib = v } +func (m *InstrumentExtension) SetDeliveryForm(v int) { m.DeliveryForm = &v } +func (m *InstrumentExtension) SetPctAtRisk(v float64) { m.PctAtRisk = &v } diff --git a/fix50sp2/instrumentleg/InstrumentLeg.go b/fix50sp2/instrumentleg/InstrumentLeg.go index 9fdeb74d6..2e25084e4 100644 --- a/fix50sp2/instrumentleg/InstrumentLeg.go +++ b/fix50sp2/instrumentleg/InstrumentLeg.go @@ -1,12 +1,8 @@ package instrumentleg -//NoLegSecurityAltID is a repeating group in InstrumentLeg -type NoLegSecurityAltID struct { - //LegSecurityAltID is a non-required field for NoLegSecurityAltID. - LegSecurityAltID *string `fix:"605"` - //LegSecurityAltIDSource is a non-required field for NoLegSecurityAltID. - LegSecurityAltIDSource *string `fix:"606"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp2/legsecaltidgrp" +) //InstrumentLeg is a fix50sp2 Component type InstrumentLeg struct { @@ -18,8 +14,8 @@ type InstrumentLeg struct { LegSecurityID *string `fix:"602"` //LegSecurityIDSource is a non-required field for InstrumentLeg. LegSecurityIDSource *string `fix:"603"` - //NoLegSecurityAltID is a non-required field for InstrumentLeg. - NoLegSecurityAltID []NoLegSecurityAltID `fix:"604,omitempty"` + //LegSecAltIDGrp Component + legsecaltidgrp.LegSecAltIDGrp //LegProduct is a non-required field for InstrumentLeg. LegProduct *int `fix:"607"` //LegCFICode is a non-required field for InstrumentLeg. @@ -120,57 +116,56 @@ type InstrumentLeg struct { LegFlowScheduleType *int `fix:"1440"` } -func (m *InstrumentLeg) SetLegSymbol(v string) { m.LegSymbol = &v } -func (m *InstrumentLeg) SetLegSymbolSfx(v string) { m.LegSymbolSfx = &v } -func (m *InstrumentLeg) SetLegSecurityID(v string) { m.LegSecurityID = &v } -func (m *InstrumentLeg) SetLegSecurityIDSource(v string) { m.LegSecurityIDSource = &v } -func (m *InstrumentLeg) SetNoLegSecurityAltID(v []NoLegSecurityAltID) { m.NoLegSecurityAltID = v } -func (m *InstrumentLeg) SetLegProduct(v int) { m.LegProduct = &v } -func (m *InstrumentLeg) SetLegCFICode(v string) { m.LegCFICode = &v } -func (m *InstrumentLeg) SetLegSecurityType(v string) { m.LegSecurityType = &v } -func (m *InstrumentLeg) SetLegSecuritySubType(v string) { m.LegSecuritySubType = &v } -func (m *InstrumentLeg) SetLegMaturityMonthYear(v string) { m.LegMaturityMonthYear = &v } -func (m *InstrumentLeg) SetLegMaturityDate(v string) { m.LegMaturityDate = &v } -func (m *InstrumentLeg) SetLegCouponPaymentDate(v string) { m.LegCouponPaymentDate = &v } -func (m *InstrumentLeg) SetLegIssueDate(v string) { m.LegIssueDate = &v } -func (m *InstrumentLeg) SetLegRepoCollateralSecurityType(v int) { m.LegRepoCollateralSecurityType = &v } -func (m *InstrumentLeg) SetLegRepurchaseTerm(v int) { m.LegRepurchaseTerm = &v } -func (m *InstrumentLeg) SetLegRepurchaseRate(v float64) { m.LegRepurchaseRate = &v } -func (m *InstrumentLeg) SetLegFactor(v float64) { m.LegFactor = &v } -func (m *InstrumentLeg) SetLegCreditRating(v string) { m.LegCreditRating = &v } -func (m *InstrumentLeg) SetLegInstrRegistry(v string) { m.LegInstrRegistry = &v } -func (m *InstrumentLeg) SetLegCountryOfIssue(v string) { m.LegCountryOfIssue = &v } -func (m *InstrumentLeg) SetLegStateOrProvinceOfIssue(v string) { m.LegStateOrProvinceOfIssue = &v } -func (m *InstrumentLeg) SetLegLocaleOfIssue(v string) { m.LegLocaleOfIssue = &v } -func (m *InstrumentLeg) SetLegRedemptionDate(v string) { m.LegRedemptionDate = &v } -func (m *InstrumentLeg) SetLegStrikePrice(v float64) { m.LegStrikePrice = &v } -func (m *InstrumentLeg) SetLegStrikeCurrency(v string) { m.LegStrikeCurrency = &v } -func (m *InstrumentLeg) SetLegOptAttribute(v string) { m.LegOptAttribute = &v } -func (m *InstrumentLeg) SetLegContractMultiplier(v float64) { m.LegContractMultiplier = &v } -func (m *InstrumentLeg) SetLegCouponRate(v float64) { m.LegCouponRate = &v } -func (m *InstrumentLeg) SetLegSecurityExchange(v string) { m.LegSecurityExchange = &v } -func (m *InstrumentLeg) SetLegIssuer(v string) { m.LegIssuer = &v } -func (m *InstrumentLeg) SetEncodedLegIssuerLen(v int) { m.EncodedLegIssuerLen = &v } -func (m *InstrumentLeg) SetEncodedLegIssuer(v string) { m.EncodedLegIssuer = &v } -func (m *InstrumentLeg) SetLegSecurityDesc(v string) { m.LegSecurityDesc = &v } -func (m *InstrumentLeg) SetEncodedLegSecurityDescLen(v int) { m.EncodedLegSecurityDescLen = &v } -func (m *InstrumentLeg) SetEncodedLegSecurityDesc(v string) { m.EncodedLegSecurityDesc = &v } -func (m *InstrumentLeg) SetLegRatioQty(v float64) { m.LegRatioQty = &v } -func (m *InstrumentLeg) SetLegSide(v string) { m.LegSide = &v } -func (m *InstrumentLeg) SetLegCurrency(v string) { m.LegCurrency = &v } -func (m *InstrumentLeg) SetLegPool(v string) { m.LegPool = &v } -func (m *InstrumentLeg) SetLegDatedDate(v string) { m.LegDatedDate = &v } -func (m *InstrumentLeg) SetLegContractSettlMonth(v string) { m.LegContractSettlMonth = &v } -func (m *InstrumentLeg) SetLegInterestAccrualDate(v string) { m.LegInterestAccrualDate = &v } -func (m *InstrumentLeg) SetLegUnitOfMeasure(v string) { m.LegUnitOfMeasure = &v } -func (m *InstrumentLeg) SetLegTimeUnit(v string) { m.LegTimeUnit = &v } -func (m *InstrumentLeg) SetLegOptionRatio(v float64) { m.LegOptionRatio = &v } -func (m *InstrumentLeg) SetLegPrice(v float64) { m.LegPrice = &v } -func (m *InstrumentLeg) SetLegMaturityTime(v string) { m.LegMaturityTime = &v } -func (m *InstrumentLeg) SetLegPutOrCall(v int) { m.LegPutOrCall = &v } -func (m *InstrumentLeg) SetLegExerciseStyle(v int) { m.LegExerciseStyle = &v } -func (m *InstrumentLeg) SetLegUnitOfMeasureQty(v float64) { m.LegUnitOfMeasureQty = &v } -func (m *InstrumentLeg) SetLegPriceUnitOfMeasure(v string) { m.LegPriceUnitOfMeasure = &v } -func (m *InstrumentLeg) SetLegPriceUnitOfMeasureQty(v float64) { m.LegPriceUnitOfMeasureQty = &v } -func (m *InstrumentLeg) SetLegContractMultiplierUnit(v int) { m.LegContractMultiplierUnit = &v } -func (m *InstrumentLeg) SetLegFlowScheduleType(v int) { m.LegFlowScheduleType = &v } +func (m *InstrumentLeg) SetLegSymbol(v string) { m.LegSymbol = &v } +func (m *InstrumentLeg) SetLegSymbolSfx(v string) { m.LegSymbolSfx = &v } +func (m *InstrumentLeg) SetLegSecurityID(v string) { m.LegSecurityID = &v } +func (m *InstrumentLeg) SetLegSecurityIDSource(v string) { m.LegSecurityIDSource = &v } +func (m *InstrumentLeg) SetLegProduct(v int) { m.LegProduct = &v } +func (m *InstrumentLeg) SetLegCFICode(v string) { m.LegCFICode = &v } +func (m *InstrumentLeg) SetLegSecurityType(v string) { m.LegSecurityType = &v } +func (m *InstrumentLeg) SetLegSecuritySubType(v string) { m.LegSecuritySubType = &v } +func (m *InstrumentLeg) SetLegMaturityMonthYear(v string) { m.LegMaturityMonthYear = &v } +func (m *InstrumentLeg) SetLegMaturityDate(v string) { m.LegMaturityDate = &v } +func (m *InstrumentLeg) SetLegCouponPaymentDate(v string) { m.LegCouponPaymentDate = &v } +func (m *InstrumentLeg) SetLegIssueDate(v string) { m.LegIssueDate = &v } +func (m *InstrumentLeg) SetLegRepoCollateralSecurityType(v int) { m.LegRepoCollateralSecurityType = &v } +func (m *InstrumentLeg) SetLegRepurchaseTerm(v int) { m.LegRepurchaseTerm = &v } +func (m *InstrumentLeg) SetLegRepurchaseRate(v float64) { m.LegRepurchaseRate = &v } +func (m *InstrumentLeg) SetLegFactor(v float64) { m.LegFactor = &v } +func (m *InstrumentLeg) SetLegCreditRating(v string) { m.LegCreditRating = &v } +func (m *InstrumentLeg) SetLegInstrRegistry(v string) { m.LegInstrRegistry = &v } +func (m *InstrumentLeg) SetLegCountryOfIssue(v string) { m.LegCountryOfIssue = &v } +func (m *InstrumentLeg) SetLegStateOrProvinceOfIssue(v string) { m.LegStateOrProvinceOfIssue = &v } +func (m *InstrumentLeg) SetLegLocaleOfIssue(v string) { m.LegLocaleOfIssue = &v } +func (m *InstrumentLeg) SetLegRedemptionDate(v string) { m.LegRedemptionDate = &v } +func (m *InstrumentLeg) SetLegStrikePrice(v float64) { m.LegStrikePrice = &v } +func (m *InstrumentLeg) SetLegStrikeCurrency(v string) { m.LegStrikeCurrency = &v } +func (m *InstrumentLeg) SetLegOptAttribute(v string) { m.LegOptAttribute = &v } +func (m *InstrumentLeg) SetLegContractMultiplier(v float64) { m.LegContractMultiplier = &v } +func (m *InstrumentLeg) SetLegCouponRate(v float64) { m.LegCouponRate = &v } +func (m *InstrumentLeg) SetLegSecurityExchange(v string) { m.LegSecurityExchange = &v } +func (m *InstrumentLeg) SetLegIssuer(v string) { m.LegIssuer = &v } +func (m *InstrumentLeg) SetEncodedLegIssuerLen(v int) { m.EncodedLegIssuerLen = &v } +func (m *InstrumentLeg) SetEncodedLegIssuer(v string) { m.EncodedLegIssuer = &v } +func (m *InstrumentLeg) SetLegSecurityDesc(v string) { m.LegSecurityDesc = &v } +func (m *InstrumentLeg) SetEncodedLegSecurityDescLen(v int) { m.EncodedLegSecurityDescLen = &v } +func (m *InstrumentLeg) SetEncodedLegSecurityDesc(v string) { m.EncodedLegSecurityDesc = &v } +func (m *InstrumentLeg) SetLegRatioQty(v float64) { m.LegRatioQty = &v } +func (m *InstrumentLeg) SetLegSide(v string) { m.LegSide = &v } +func (m *InstrumentLeg) SetLegCurrency(v string) { m.LegCurrency = &v } +func (m *InstrumentLeg) SetLegPool(v string) { m.LegPool = &v } +func (m *InstrumentLeg) SetLegDatedDate(v string) { m.LegDatedDate = &v } +func (m *InstrumentLeg) SetLegContractSettlMonth(v string) { m.LegContractSettlMonth = &v } +func (m *InstrumentLeg) SetLegInterestAccrualDate(v string) { m.LegInterestAccrualDate = &v } +func (m *InstrumentLeg) SetLegUnitOfMeasure(v string) { m.LegUnitOfMeasure = &v } +func (m *InstrumentLeg) SetLegTimeUnit(v string) { m.LegTimeUnit = &v } +func (m *InstrumentLeg) SetLegOptionRatio(v float64) { m.LegOptionRatio = &v } +func (m *InstrumentLeg) SetLegPrice(v float64) { m.LegPrice = &v } +func (m *InstrumentLeg) SetLegMaturityTime(v string) { m.LegMaturityTime = &v } +func (m *InstrumentLeg) SetLegPutOrCall(v int) { m.LegPutOrCall = &v } +func (m *InstrumentLeg) SetLegExerciseStyle(v int) { m.LegExerciseStyle = &v } +func (m *InstrumentLeg) SetLegUnitOfMeasureQty(v float64) { m.LegUnitOfMeasureQty = &v } +func (m *InstrumentLeg) SetLegPriceUnitOfMeasure(v string) { m.LegPriceUnitOfMeasure = &v } +func (m *InstrumentLeg) SetLegPriceUnitOfMeasureQty(v float64) { m.LegPriceUnitOfMeasureQty = &v } +func (m *InstrumentLeg) SetLegContractMultiplierUnit(v int) { m.LegContractMultiplierUnit = &v } +func (m *InstrumentLeg) SetLegFlowScheduleType(v int) { m.LegFlowScheduleType = &v } diff --git a/fix50sp2/partydetail/PartyDetail.go b/fix50sp2/partydetail/PartyDetail.go index ade16249e..63bb47234 100644 --- a/fix50sp2/partydetail/PartyDetail.go +++ b/fix50sp2/partydetail/PartyDetail.go @@ -1,58 +1,12 @@ package partydetail import ( - "github.com/quickfixgo/quickfix/fix50sp2/altptyssubgrp" - "github.com/quickfixgo/quickfix/fix50sp2/contextptyssubgrp" - "github.com/quickfixgo/quickfix/fix50sp2/riskinstrumentscope" - "github.com/quickfixgo/quickfix/fix50sp2/riskwarninglevels" + "github.com/quickfixgo/quickfix/fix50sp2/contextparties" + "github.com/quickfixgo/quickfix/fix50sp2/partyaltids" + "github.com/quickfixgo/quickfix/fix50sp2/ptyssubgrp" + "github.com/quickfixgo/quickfix/fix50sp2/risklimits" ) -//NoPartySubIDs is a repeating group in PartyDetail -type NoPartySubIDs struct { - //PartySubID is a non-required field for NoPartySubIDs. - PartySubID *string `fix:"523"` - //PartySubIDType is a non-required field for NoPartySubIDs. - PartySubIDType *int `fix:"803"` -} - -//NoPartyAltIDs is a repeating group in PartyDetail -type NoPartyAltIDs struct { - //PartyAltID is a non-required field for NoPartyAltIDs. - PartyAltID *string `fix:"1517"` - //PartyAltIDSource is a non-required field for NoPartyAltIDs. - PartyAltIDSource *string `fix:"1518"` - //AltPtysSubGrp Component - altptyssubgrp.AltPtysSubGrp -} - -//NoContextPartyIDs is a repeating group in PartyDetail -type NoContextPartyIDs struct { - //ContextPartyID is a non-required field for NoContextPartyIDs. - ContextPartyID *string `fix:"1523"` - //ContextPartyIDSource is a non-required field for NoContextPartyIDs. - ContextPartyIDSource *string `fix:"1524"` - //ContextPartyRole is a non-required field for NoContextPartyIDs. - ContextPartyRole *int `fix:"1525"` - //ContextPtysSubGrp Component - contextptyssubgrp.ContextPtysSubGrp -} - -//NoRiskLimits is a repeating group in PartyDetail -type NoRiskLimits struct { - //RiskLimitType is a non-required field for NoRiskLimits. - RiskLimitType *int `fix:"1530"` - //RiskLimitAmount is a non-required field for NoRiskLimits. - RiskLimitAmount *float64 `fix:"1531"` - //RiskLimitCurrency is a non-required field for NoRiskLimits. - RiskLimitCurrency *string `fix:"1532"` - //RiskLimitPlatform is a non-required field for NoRiskLimits. - RiskLimitPlatform *string `fix:"1533"` - //RiskInstrumentScope Component - riskinstrumentscope.RiskInstrumentScope - //RiskWarningLevels Component - riskwarninglevels.RiskWarningLevels -} - //PartyDetail is a fix50sp2 Component type PartyDetail struct { //PartyID is a required field for PartyDetail. @@ -61,20 +15,16 @@ type PartyDetail struct { PartyIDSource string `fix:"447"` //PartyRole is a required field for PartyDetail. PartyRole int `fix:"452"` - //NoPartySubIDs is a non-required field for PartyDetail. - NoPartySubIDs []NoPartySubIDs `fix:"802,omitempty"` - //NoPartyAltIDs is a non-required field for PartyDetail. - NoPartyAltIDs []NoPartyAltIDs `fix:"1516,omitempty"` - //NoContextPartyIDs is a non-required field for PartyDetail. - NoContextPartyIDs []NoContextPartyIDs `fix:"1522,omitempty"` - //NoRiskLimits is a non-required field for PartyDetail. - NoRiskLimits []NoRiskLimits `fix:"1529,omitempty"` + //PtysSubGrp Component + ptyssubgrp.PtysSubGrp + //PartyAltIDs Component + partyaltids.PartyAltIDs + //ContextParties Component + contextparties.ContextParties + //RiskLimits Component + risklimits.RiskLimits } -func (m *PartyDetail) SetPartyID(v string) { m.PartyID = v } -func (m *PartyDetail) SetPartyIDSource(v string) { m.PartyIDSource = v } -func (m *PartyDetail) SetPartyRole(v int) { m.PartyRole = v } -func (m *PartyDetail) SetNoPartySubIDs(v []NoPartySubIDs) { m.NoPartySubIDs = v } -func (m *PartyDetail) SetNoPartyAltIDs(v []NoPartyAltIDs) { m.NoPartyAltIDs = v } -func (m *PartyDetail) SetNoContextPartyIDs(v []NoContextPartyIDs) { m.NoContextPartyIDs = v } -func (m *PartyDetail) SetNoRiskLimits(v []NoRiskLimits) { m.NoRiskLimits = v } +func (m *PartyDetail) SetPartyID(v string) { m.PartyID = v } +func (m *PartyDetail) SetPartyIDSource(v string) { m.PartyIDSource = v } +func (m *PartyDetail) SetPartyRole(v int) { m.PartyRole = v } diff --git a/fix50sp2/relatedpartydetail/RelatedPartyDetail.go b/fix50sp2/relatedpartydetail/RelatedPartyDetail.go index 202859744..e02fea172 100644 --- a/fix50sp2/relatedpartydetail/RelatedPartyDetail.go +++ b/fix50sp2/relatedpartydetail/RelatedPartyDetail.go @@ -1,58 +1,12 @@ package relatedpartydetail import ( - "github.com/quickfixgo/quickfix/fix50sp2/relatedaltptyssubgrp" - "github.com/quickfixgo/quickfix/fix50sp2/relatedcontextptyssubgrp" - "github.com/quickfixgo/quickfix/fix50sp2/relationshipriskinstrumentscope" - "github.com/quickfixgo/quickfix/fix50sp2/relationshipriskwarninglevels" + "github.com/quickfixgo/quickfix/fix50sp2/relatedcontextparties" + "github.com/quickfixgo/quickfix/fix50sp2/relatedpartyaltids" + "github.com/quickfixgo/quickfix/fix50sp2/relatedptyssubgrp" + "github.com/quickfixgo/quickfix/fix50sp2/relationshiprisklimits" ) -//NoRelatedPartySubIDs is a repeating group in RelatedPartyDetail -type NoRelatedPartySubIDs struct { - //RelatedPartySubID is a non-required field for NoRelatedPartySubIDs. - RelatedPartySubID *string `fix:"1567"` - //RelatedPartySubIDType is a non-required field for NoRelatedPartySubIDs. - RelatedPartySubIDType *int `fix:"1568"` -} - -//NoRelatedPartyAltIDs is a repeating group in RelatedPartyDetail -type NoRelatedPartyAltIDs struct { - //RelatedPartyAltID is a non-required field for NoRelatedPartyAltIDs. - RelatedPartyAltID *string `fix:"1570"` - //RelatedPartyAltIDSource is a non-required field for NoRelatedPartyAltIDs. - RelatedPartyAltIDSource *string `fix:"1571"` - //RelatedAltPtysSubGrp Component - relatedaltptyssubgrp.RelatedAltPtysSubGrp -} - -//NoRelatedContextPartyIDs is a repeating group in RelatedPartyDetail -type NoRelatedContextPartyIDs struct { - //RelatedContextPartyID is a non-required field for NoRelatedContextPartyIDs. - RelatedContextPartyID *string `fix:"1576"` - //RelatedContextPartyIDSource is a non-required field for NoRelatedContextPartyIDs. - RelatedContextPartyIDSource *string `fix:"1577"` - //RelatedContextPartyRole is a non-required field for NoRelatedContextPartyIDs. - RelatedContextPartyRole *int `fix:"1578"` - //RelatedContextPtysSubGrp Component - relatedcontextptyssubgrp.RelatedContextPtysSubGrp -} - -//NoRelationshipRiskLimits is a repeating group in RelatedPartyDetail -type NoRelationshipRiskLimits struct { - //RelationshipRiskLimitType is a non-required field for NoRelationshipRiskLimits. - RelationshipRiskLimitType *int `fix:"1583"` - //RelationshipRiskLimitAmount is a non-required field for NoRelationshipRiskLimits. - RelationshipRiskLimitAmount *float64 `fix:"1584"` - //RelationshipRiskLimitCurrency is a non-required field for NoRelationshipRiskLimits. - RelationshipRiskLimitCurrency *string `fix:"1585"` - //RelationshipRiskLimitPlatform is a non-required field for NoRelationshipRiskLimits. - RelationshipRiskLimitPlatform *string `fix:"1586"` - //RelationshipRiskInstrumentScope Component - relationshipriskinstrumentscope.RelationshipRiskInstrumentScope - //RelationshipRiskWarningLevels Component - relationshipriskwarninglevels.RelationshipRiskWarningLevels -} - //RelatedPartyDetail is a fix50sp2 Component type RelatedPartyDetail struct { //RelatedPartyID is a non-required field for RelatedPartyDetail. @@ -61,28 +15,16 @@ type RelatedPartyDetail struct { RelatedPartyIDSource *string `fix:"1564"` //RelatedPartyRole is a non-required field for RelatedPartyDetail. RelatedPartyRole *int `fix:"1565"` - //NoRelatedPartySubIDs is a non-required field for RelatedPartyDetail. - NoRelatedPartySubIDs []NoRelatedPartySubIDs `fix:"1566,omitempty"` - //NoRelatedPartyAltIDs is a non-required field for RelatedPartyDetail. - NoRelatedPartyAltIDs []NoRelatedPartyAltIDs `fix:"1569,omitempty"` - //NoRelatedContextPartyIDs is a non-required field for RelatedPartyDetail. - NoRelatedContextPartyIDs []NoRelatedContextPartyIDs `fix:"1575,omitempty"` - //NoRelationshipRiskLimits is a non-required field for RelatedPartyDetail. - NoRelationshipRiskLimits []NoRelationshipRiskLimits `fix:"1582,omitempty"` + //RelatedPtysSubGrp Component + relatedptyssubgrp.RelatedPtysSubGrp + //RelatedPartyAltIDs Component + relatedpartyaltids.RelatedPartyAltIDs + //RelatedContextParties Component + relatedcontextparties.RelatedContextParties + //RelationshipRiskLimits Component + relationshiprisklimits.RelationshipRiskLimits } func (m *RelatedPartyDetail) SetRelatedPartyID(v string) { m.RelatedPartyID = &v } func (m *RelatedPartyDetail) SetRelatedPartyIDSource(v string) { m.RelatedPartyIDSource = &v } func (m *RelatedPartyDetail) SetRelatedPartyRole(v int) { m.RelatedPartyRole = &v } -func (m *RelatedPartyDetail) SetNoRelatedPartySubIDs(v []NoRelatedPartySubIDs) { - m.NoRelatedPartySubIDs = v -} -func (m *RelatedPartyDetail) SetNoRelatedPartyAltIDs(v []NoRelatedPartyAltIDs) { - m.NoRelatedPartyAltIDs = v -} -func (m *RelatedPartyDetail) SetNoRelatedContextPartyIDs(v []NoRelatedContextPartyIDs) { - m.NoRelatedContextPartyIDs = v -} -func (m *RelatedPartyDetail) SetNoRelationshipRiskLimits(v []NoRelationshipRiskLimits) { - m.NoRelationshipRiskLimits = v -} diff --git a/fix50sp2/securitytradingrules/SecurityTradingRules.go b/fix50sp2/securitytradingrules/SecurityTradingRules.go index ae6fd4802..83bd89592 100644 --- a/fix50sp2/securitytradingrules/SecurityTradingRules.go +++ b/fix50sp2/securitytradingrules/SecurityTradingRules.go @@ -1,106 +1,17 @@ package securitytradingrules import ( - "github.com/quickfixgo/quickfix/fix50sp2/tradingsessionrules" + "github.com/quickfixgo/quickfix/fix50sp2/basetradingrules" + "github.com/quickfixgo/quickfix/fix50sp2/nestedinstrumentattribute" + "github.com/quickfixgo/quickfix/fix50sp2/tradingsessionrulesgrp" ) -//NoTickRules is a repeating group in SecurityTradingRules -type NoTickRules struct { - //StartTickPriceRange is a non-required field for NoTickRules. - StartTickPriceRange *float64 `fix:"1206"` - //EndTickPriceRange is a non-required field for NoTickRules. - EndTickPriceRange *float64 `fix:"1207"` - //TickIncrement is a non-required field for NoTickRules. - TickIncrement *float64 `fix:"1208"` - //TickRuleType is a non-required field for NoTickRules. - TickRuleType *int `fix:"1209"` -} - -//NoLotTypeRules is a repeating group in SecurityTradingRules -type NoLotTypeRules struct { - //LotType is a non-required field for NoLotTypeRules. - LotType *string `fix:"1093"` - //MinLotSize is a non-required field for NoLotTypeRules. - MinLotSize *float64 `fix:"1231"` -} - -//NoTradingSessionRules is a repeating group in SecurityTradingRules -type NoTradingSessionRules struct { - //TradingSessionID is a non-required field for NoTradingSessionRules. - TradingSessionID *string `fix:"336"` - //TradingSessionSubID is a non-required field for NoTradingSessionRules. - TradingSessionSubID *string `fix:"625"` - //TradingSessionRules Component - tradingsessionrules.TradingSessionRules -} - -//NoNestedInstrAttrib is a repeating group in SecurityTradingRules -type NoNestedInstrAttrib struct { - //NestedInstrAttribType is a non-required field for NoNestedInstrAttrib. - NestedInstrAttribType *int `fix:"1210"` - //NestedInstrAttribValue is a non-required field for NoNestedInstrAttrib. - NestedInstrAttribValue *string `fix:"1211"` -} - //SecurityTradingRules is a fix50sp2 Component type SecurityTradingRules struct { - //NoTickRules is a non-required field for SecurityTradingRules. - NoTickRules []NoTickRules `fix:"1205,omitempty"` - //NoLotTypeRules is a non-required field for SecurityTradingRules. - NoLotTypeRules []NoLotTypeRules `fix:"1234,omitempty"` - //PriceLimitType is a non-required field for SecurityTradingRules. - PriceLimitType *int `fix:"1306"` - //LowLimitPrice is a non-required field for SecurityTradingRules. - LowLimitPrice *float64 `fix:"1148"` - //HighLimitPrice is a non-required field for SecurityTradingRules. - HighLimitPrice *float64 `fix:"1149"` - //TradingReferencePrice is a non-required field for SecurityTradingRules. - TradingReferencePrice *float64 `fix:"1150"` - //ExpirationCycle is a non-required field for SecurityTradingRules. - ExpirationCycle *int `fix:"827"` - //MinTradeVol is a non-required field for SecurityTradingRules. - MinTradeVol *float64 `fix:"562"` - //MaxTradeVol is a non-required field for SecurityTradingRules. - MaxTradeVol *float64 `fix:"1140"` - //MaxPriceVariation is a non-required field for SecurityTradingRules. - MaxPriceVariation *float64 `fix:"1143"` - //ImpliedMarketIndicator is a non-required field for SecurityTradingRules. - ImpliedMarketIndicator *int `fix:"1144"` - //TradingCurrency is a non-required field for SecurityTradingRules. - TradingCurrency *string `fix:"1245"` - //RoundLot is a non-required field for SecurityTradingRules. - RoundLot *float64 `fix:"561"` - //MultilegModel is a non-required field for SecurityTradingRules. - MultilegModel *int `fix:"1377"` - //MultilegPriceMethod is a non-required field for SecurityTradingRules. - MultilegPriceMethod *int `fix:"1378"` - //PriceType is a non-required field for SecurityTradingRules. - PriceType *int `fix:"423"` - //NoTradingSessionRules is a non-required field for SecurityTradingRules. - NoTradingSessionRules []NoTradingSessionRules `fix:"1309,omitempty"` - //NoNestedInstrAttrib is a non-required field for SecurityTradingRules. - NoNestedInstrAttrib []NoNestedInstrAttrib `fix:"1312,omitempty"` -} - -func (m *SecurityTradingRules) SetNoTickRules(v []NoTickRules) { m.NoTickRules = v } -func (m *SecurityTradingRules) SetNoLotTypeRules(v []NoLotTypeRules) { m.NoLotTypeRules = v } -func (m *SecurityTradingRules) SetPriceLimitType(v int) { m.PriceLimitType = &v } -func (m *SecurityTradingRules) SetLowLimitPrice(v float64) { m.LowLimitPrice = &v } -func (m *SecurityTradingRules) SetHighLimitPrice(v float64) { m.HighLimitPrice = &v } -func (m *SecurityTradingRules) SetTradingReferencePrice(v float64) { m.TradingReferencePrice = &v } -func (m *SecurityTradingRules) SetExpirationCycle(v int) { m.ExpirationCycle = &v } -func (m *SecurityTradingRules) SetMinTradeVol(v float64) { m.MinTradeVol = &v } -func (m *SecurityTradingRules) SetMaxTradeVol(v float64) { m.MaxTradeVol = &v } -func (m *SecurityTradingRules) SetMaxPriceVariation(v float64) { m.MaxPriceVariation = &v } -func (m *SecurityTradingRules) SetImpliedMarketIndicator(v int) { m.ImpliedMarketIndicator = &v } -func (m *SecurityTradingRules) SetTradingCurrency(v string) { m.TradingCurrency = &v } -func (m *SecurityTradingRules) SetRoundLot(v float64) { m.RoundLot = &v } -func (m *SecurityTradingRules) SetMultilegModel(v int) { m.MultilegModel = &v } -func (m *SecurityTradingRules) SetMultilegPriceMethod(v int) { m.MultilegPriceMethod = &v } -func (m *SecurityTradingRules) SetPriceType(v int) { m.PriceType = &v } -func (m *SecurityTradingRules) SetNoTradingSessionRules(v []NoTradingSessionRules) { - m.NoTradingSessionRules = v -} -func (m *SecurityTradingRules) SetNoNestedInstrAttrib(v []NoNestedInstrAttrib) { - m.NoNestedInstrAttrib = v + //BaseTradingRules Component + basetradingrules.BaseTradingRules + //TradingSessionRulesGrp Component + tradingsessionrulesgrp.TradingSessionRulesGrp + //NestedInstrumentAttribute Component + nestedinstrumentattribute.NestedInstrumentAttribute } diff --git a/fix50sp2/settlinstructionsdata/SettlInstructionsData.go b/fix50sp2/settlinstructionsdata/SettlInstructionsData.go index 5822f19d0..08c20c055 100644 --- a/fix50sp2/settlinstructionsdata/SettlInstructionsData.go +++ b/fix50sp2/settlinstructionsdata/SettlInstructionsData.go @@ -1,19 +1,9 @@ package settlinstructionsdata import ( - "github.com/quickfixgo/quickfix/fix50sp2/settlparties" + "github.com/quickfixgo/quickfix/fix50sp2/dlvyinstgrp" ) -//NoDlvyInst is a repeating group in SettlInstructionsData -type NoDlvyInst struct { - //SettlInstSource is a non-required field for NoDlvyInst. - SettlInstSource *string `fix:"165"` - //DlvyInstType is a non-required field for NoDlvyInst. - DlvyInstType *string `fix:"787"` - //SettlParties Component - settlparties.SettlParties -} - //SettlInstructionsData is a fix50sp2 Component type SettlInstructionsData struct { //SettlDeliveryType is a non-required field for SettlInstructionsData. @@ -24,12 +14,11 @@ type SettlInstructionsData struct { StandInstDbName *string `fix:"170"` //StandInstDbID is a non-required field for SettlInstructionsData. StandInstDbID *string `fix:"171"` - //NoDlvyInst is a non-required field for SettlInstructionsData. - NoDlvyInst []NoDlvyInst `fix:"85,omitempty"` + //DlvyInstGrp Component + dlvyinstgrp.DlvyInstGrp } -func (m *SettlInstructionsData) SetSettlDeliveryType(v int) { m.SettlDeliveryType = &v } -func (m *SettlInstructionsData) SetStandInstDbType(v int) { m.StandInstDbType = &v } -func (m *SettlInstructionsData) SetStandInstDbName(v string) { m.StandInstDbName = &v } -func (m *SettlInstructionsData) SetStandInstDbID(v string) { m.StandInstDbID = &v } -func (m *SettlInstructionsData) SetNoDlvyInst(v []NoDlvyInst) { m.NoDlvyInst = v } +func (m *SettlInstructionsData) SetSettlDeliveryType(v int) { m.SettlDeliveryType = &v } +func (m *SettlInstructionsData) SetStandInstDbType(v int) { m.StandInstDbType = &v } +func (m *SettlInstructionsData) SetStandInstDbName(v string) { m.StandInstDbName = &v } +func (m *SettlInstructionsData) SetStandInstDbID(v string) { m.StandInstDbID = &v } diff --git a/fix50sp2/tradereportorderdetail/TradeReportOrderDetail.go b/fix50sp2/tradereportorderdetail/TradeReportOrderDetail.go index 0de6e5d8c..c272c79b6 100644 --- a/fix50sp2/tradereportorderdetail/TradeReportOrderDetail.go +++ b/fix50sp2/tradereportorderdetail/TradeReportOrderDetail.go @@ -1,6 +1,8 @@ package tradereportorderdetail import ( + "github.com/quickfixgo/quickfix/fix50sp2/displayinstruction" + "github.com/quickfixgo/quickfix/fix50sp2/orderqtydata" "time" ) @@ -32,16 +34,8 @@ type TradeReportOrderDetail struct { ExecInst *string `fix:"18"` //OrdStatus is a non-required field for TradeReportOrderDetail. OrdStatus *string `fix:"39"` - //OrderQty is a non-required field for TradeReportOrderDetail. - OrderQty *float64 `fix:"38"` - //CashOrderQty is a non-required field for TradeReportOrderDetail. - CashOrderQty *float64 `fix:"152"` - //OrderPercent is a non-required field for TradeReportOrderDetail. - OrderPercent *float64 `fix:"516"` - //RoundingDirection is a non-required field for TradeReportOrderDetail. - RoundingDirection *string `fix:"468"` - //RoundingModulus is a non-required field for TradeReportOrderDetail. - RoundingModulus *float64 `fix:"469"` + //OrderQtyData Component + orderqtydata.OrderQtyData //LeavesQty is a non-required field for TradeReportOrderDetail. LeavesQty *float64 `fix:"151"` //CumQty is a non-required field for TradeReportOrderDetail. @@ -50,22 +44,8 @@ type TradeReportOrderDetail struct { TimeInForce *string `fix:"59"` //ExpireTime is a non-required field for TradeReportOrderDetail. ExpireTime *time.Time `fix:"126"` - //SecondaryDisplayQty is a non-required field for TradeReportOrderDetail. - SecondaryDisplayQty *float64 `fix:"1082"` - //DisplayWhen is a non-required field for TradeReportOrderDetail. - DisplayWhen *string `fix:"1083"` - //DisplayMethod is a non-required field for TradeReportOrderDetail. - DisplayMethod *string `fix:"1084"` - //DisplayLowQty is a non-required field for TradeReportOrderDetail. - DisplayLowQty *float64 `fix:"1085"` - //DisplayHighQty is a non-required field for TradeReportOrderDetail. - DisplayHighQty *float64 `fix:"1086"` - //DisplayMinIncr is a non-required field for TradeReportOrderDetail. - DisplayMinIncr *float64 `fix:"1087"` - //RefreshQty is a non-required field for TradeReportOrderDetail. - RefreshQty *float64 `fix:"1088"` - //DisplayQty is a non-required field for TradeReportOrderDetail. - DisplayQty *float64 `fix:"1138"` + //DisplayInstruction Component + displayinstruction.DisplayInstruction //OrderCapacity is a non-required field for TradeReportOrderDetail. OrderCapacity *string `fix:"528"` //OrderRestrictions is a non-required field for TradeReportOrderDetail. @@ -84,41 +64,28 @@ type TradeReportOrderDetail struct { BookingType *int `fix:"775"` } -func (m *TradeReportOrderDetail) SetOrderID(v string) { m.OrderID = &v } -func (m *TradeReportOrderDetail) SetSecondaryOrderID(v string) { m.SecondaryOrderID = &v } -func (m *TradeReportOrderDetail) SetClOrdID(v string) { m.ClOrdID = &v } -func (m *TradeReportOrderDetail) SetSecondaryClOrdID(v string) { m.SecondaryClOrdID = &v } -func (m *TradeReportOrderDetail) SetListID(v string) { m.ListID = &v } -func (m *TradeReportOrderDetail) SetRefOrderID(v string) { m.RefOrderID = &v } -func (m *TradeReportOrderDetail) SetRefOrderIDSource(v string) { m.RefOrderIDSource = &v } -func (m *TradeReportOrderDetail) SetRefOrdIDReason(v int) { m.RefOrdIDReason = &v } -func (m *TradeReportOrderDetail) SetOrdType(v string) { m.OrdType = &v } -func (m *TradeReportOrderDetail) SetPrice(v float64) { m.Price = &v } -func (m *TradeReportOrderDetail) SetStopPx(v float64) { m.StopPx = &v } -func (m *TradeReportOrderDetail) SetExecInst(v string) { m.ExecInst = &v } -func (m *TradeReportOrderDetail) SetOrdStatus(v string) { m.OrdStatus = &v } -func (m *TradeReportOrderDetail) SetOrderQty(v float64) { m.OrderQty = &v } -func (m *TradeReportOrderDetail) SetCashOrderQty(v float64) { m.CashOrderQty = &v } -func (m *TradeReportOrderDetail) SetOrderPercent(v float64) { m.OrderPercent = &v } -func (m *TradeReportOrderDetail) SetRoundingDirection(v string) { m.RoundingDirection = &v } -func (m *TradeReportOrderDetail) SetRoundingModulus(v float64) { m.RoundingModulus = &v } -func (m *TradeReportOrderDetail) SetLeavesQty(v float64) { m.LeavesQty = &v } -func (m *TradeReportOrderDetail) SetCumQty(v float64) { m.CumQty = &v } -func (m *TradeReportOrderDetail) SetTimeInForce(v string) { m.TimeInForce = &v } -func (m *TradeReportOrderDetail) SetExpireTime(v time.Time) { m.ExpireTime = &v } -func (m *TradeReportOrderDetail) SetSecondaryDisplayQty(v float64) { m.SecondaryDisplayQty = &v } -func (m *TradeReportOrderDetail) SetDisplayWhen(v string) { m.DisplayWhen = &v } -func (m *TradeReportOrderDetail) SetDisplayMethod(v string) { m.DisplayMethod = &v } -func (m *TradeReportOrderDetail) SetDisplayLowQty(v float64) { m.DisplayLowQty = &v } -func (m *TradeReportOrderDetail) SetDisplayHighQty(v float64) { m.DisplayHighQty = &v } -func (m *TradeReportOrderDetail) SetDisplayMinIncr(v float64) { m.DisplayMinIncr = &v } -func (m *TradeReportOrderDetail) SetRefreshQty(v float64) { m.RefreshQty = &v } -func (m *TradeReportOrderDetail) SetDisplayQty(v float64) { m.DisplayQty = &v } -func (m *TradeReportOrderDetail) SetOrderCapacity(v string) { m.OrderCapacity = &v } -func (m *TradeReportOrderDetail) SetOrderRestrictions(v string) { m.OrderRestrictions = &v } -func (m *TradeReportOrderDetail) SetOrigCustOrderCapacity(v int) { m.OrigCustOrderCapacity = &v } -func (m *TradeReportOrderDetail) SetOrderInputDevice(v string) { m.OrderInputDevice = &v } -func (m *TradeReportOrderDetail) SetLotType(v string) { m.LotType = &v } -func (m *TradeReportOrderDetail) SetTransBkdTime(v time.Time) { m.TransBkdTime = &v } -func (m *TradeReportOrderDetail) SetOrigOrdModTime(v time.Time) { m.OrigOrdModTime = &v } -func (m *TradeReportOrderDetail) SetBookingType(v int) { m.BookingType = &v } +func (m *TradeReportOrderDetail) SetOrderID(v string) { m.OrderID = &v } +func (m *TradeReportOrderDetail) SetSecondaryOrderID(v string) { m.SecondaryOrderID = &v } +func (m *TradeReportOrderDetail) SetClOrdID(v string) { m.ClOrdID = &v } +func (m *TradeReportOrderDetail) SetSecondaryClOrdID(v string) { m.SecondaryClOrdID = &v } +func (m *TradeReportOrderDetail) SetListID(v string) { m.ListID = &v } +func (m *TradeReportOrderDetail) SetRefOrderID(v string) { m.RefOrderID = &v } +func (m *TradeReportOrderDetail) SetRefOrderIDSource(v string) { m.RefOrderIDSource = &v } +func (m *TradeReportOrderDetail) SetRefOrdIDReason(v int) { m.RefOrdIDReason = &v } +func (m *TradeReportOrderDetail) SetOrdType(v string) { m.OrdType = &v } +func (m *TradeReportOrderDetail) SetPrice(v float64) { m.Price = &v } +func (m *TradeReportOrderDetail) SetStopPx(v float64) { m.StopPx = &v } +func (m *TradeReportOrderDetail) SetExecInst(v string) { m.ExecInst = &v } +func (m *TradeReportOrderDetail) SetOrdStatus(v string) { m.OrdStatus = &v } +func (m *TradeReportOrderDetail) SetLeavesQty(v float64) { m.LeavesQty = &v } +func (m *TradeReportOrderDetail) SetCumQty(v float64) { m.CumQty = &v } +func (m *TradeReportOrderDetail) SetTimeInForce(v string) { m.TimeInForce = &v } +func (m *TradeReportOrderDetail) SetExpireTime(v time.Time) { m.ExpireTime = &v } +func (m *TradeReportOrderDetail) SetOrderCapacity(v string) { m.OrderCapacity = &v } +func (m *TradeReportOrderDetail) SetOrderRestrictions(v string) { m.OrderRestrictions = &v } +func (m *TradeReportOrderDetail) SetOrigCustOrderCapacity(v int) { m.OrigCustOrderCapacity = &v } +func (m *TradeReportOrderDetail) SetOrderInputDevice(v string) { m.OrderInputDevice = &v } +func (m *TradeReportOrderDetail) SetLotType(v string) { m.LotType = &v } +func (m *TradeReportOrderDetail) SetTransBkdTime(v time.Time) { m.TransBkdTime = &v } +func (m *TradeReportOrderDetail) SetOrigOrdModTime(v time.Time) { m.OrigOrdModTime = &v } +func (m *TradeReportOrderDetail) SetBookingType(v int) { m.BookingType = &v } diff --git a/fix50sp2/tradingsessionrules/TradingSessionRules.go b/fix50sp2/tradingsessionrules/TradingSessionRules.go index 4a9d18ab3..3710de04b 100644 --- a/fix50sp2/tradingsessionrules/TradingSessionRules.go +++ b/fix50sp2/tradingsessionrules/TradingSessionRules.go @@ -1,57 +1,23 @@ package tradingsessionrules -//NoOrdTypeRules is a repeating group in TradingSessionRules -type NoOrdTypeRules struct { - //OrdType is a non-required field for NoOrdTypeRules. - OrdType *string `fix:"40"` -} - -//NoTimeInForceRules is a repeating group in TradingSessionRules -type NoTimeInForceRules struct { - //TimeInForce is a non-required field for NoTimeInForceRules. - TimeInForce *string `fix:"59"` -} - -//NoExecInstRules is a repeating group in TradingSessionRules -type NoExecInstRules struct { - //ExecInstValue is a non-required field for NoExecInstRules. - ExecInstValue *string `fix:"1308"` -} - -//NoMatchRules is a repeating group in TradingSessionRules -type NoMatchRules struct { - //MatchAlgorithm is a non-required field for NoMatchRules. - MatchAlgorithm *string `fix:"1142"` - //MatchType is a non-required field for NoMatchRules. - MatchType *string `fix:"574"` -} - -//NoMDFeedTypes is a repeating group in TradingSessionRules -type NoMDFeedTypes struct { - //MDFeedType is a non-required field for NoMDFeedTypes. - MDFeedType *string `fix:"1022"` - //MarketDepth is a non-required field for NoMDFeedTypes. - MarketDepth *int `fix:"264"` - //MDBookType is a non-required field for NoMDFeedTypes. - MDBookType *int `fix:"1021"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp2/execinstrules" + "github.com/quickfixgo/quickfix/fix50sp2/marketdatafeedtypes" + "github.com/quickfixgo/quickfix/fix50sp2/matchrules" + "github.com/quickfixgo/quickfix/fix50sp2/ordtyperules" + "github.com/quickfixgo/quickfix/fix50sp2/timeinforcerules" +) //TradingSessionRules is a fix50sp2 Component type TradingSessionRules struct { - //NoOrdTypeRules is a non-required field for TradingSessionRules. - NoOrdTypeRules []NoOrdTypeRules `fix:"1237,omitempty"` - //NoTimeInForceRules is a non-required field for TradingSessionRules. - NoTimeInForceRules []NoTimeInForceRules `fix:"1239,omitempty"` - //NoExecInstRules is a non-required field for TradingSessionRules. - NoExecInstRules []NoExecInstRules `fix:"1232,omitempty"` - //NoMatchRules is a non-required field for TradingSessionRules. - NoMatchRules []NoMatchRules `fix:"1235,omitempty"` - //NoMDFeedTypes is a non-required field for TradingSessionRules. - NoMDFeedTypes []NoMDFeedTypes `fix:"1141,omitempty"` + //OrdTypeRules Component + ordtyperules.OrdTypeRules + //TimeInForceRules Component + timeinforcerules.TimeInForceRules + //ExecInstRules Component + execinstrules.ExecInstRules + //MatchRules Component + matchrules.MatchRules + //MarketDataFeedTypes Component + marketdatafeedtypes.MarketDataFeedTypes } - -func (m *TradingSessionRules) SetNoOrdTypeRules(v []NoOrdTypeRules) { m.NoOrdTypeRules = v } -func (m *TradingSessionRules) SetNoTimeInForceRules(v []NoTimeInForceRules) { m.NoTimeInForceRules = v } -func (m *TradingSessionRules) SetNoExecInstRules(v []NoExecInstRules) { m.NoExecInstRules = v } -func (m *TradingSessionRules) SetNoMatchRules(v []NoMatchRules) { m.NoMatchRules = v } -func (m *TradingSessionRules) SetNoMDFeedTypes(v []NoMDFeedTypes) { m.NoMDFeedTypes = v } diff --git a/fix50sp2/underlyinginstrument/UnderlyingInstrument.go b/fix50sp2/underlyinginstrument/UnderlyingInstrument.go index 54bb676ce..ae2889e6e 100644 --- a/fix50sp2/underlyinginstrument/UnderlyingInstrument.go +++ b/fix50sp2/underlyinginstrument/UnderlyingInstrument.go @@ -1,37 +1,11 @@ package underlyinginstrument import ( - "github.com/quickfixgo/quickfix/fix50sp2/undlyinstrumentptyssubgrp" + "github.com/quickfixgo/quickfix/fix50sp2/underlyingstipulations" + "github.com/quickfixgo/quickfix/fix50sp2/undlyinstrumentparties" + "github.com/quickfixgo/quickfix/fix50sp2/undsecaltidgrp" ) -//NoUnderlyingSecurityAltID is a repeating group in UnderlyingInstrument -type NoUnderlyingSecurityAltID struct { - //UnderlyingSecurityAltID is a non-required field for NoUnderlyingSecurityAltID. - UnderlyingSecurityAltID *string `fix:"458"` - //UnderlyingSecurityAltIDSource is a non-required field for NoUnderlyingSecurityAltID. - UnderlyingSecurityAltIDSource *string `fix:"459"` -} - -//NoUnderlyingStips is a repeating group in UnderlyingInstrument -type NoUnderlyingStips struct { - //UnderlyingStipType is a non-required field for NoUnderlyingStips. - UnderlyingStipType *string `fix:"888"` - //UnderlyingStipValue is a non-required field for NoUnderlyingStips. - UnderlyingStipValue *string `fix:"889"` -} - -//NoUndlyInstrumentParties is a repeating group in UnderlyingInstrument -type NoUndlyInstrumentParties struct { - //UnderlyingInstrumentPartyID is a non-required field for NoUndlyInstrumentParties. - UnderlyingInstrumentPartyID *string `fix:"1059"` - //UnderlyingInstrumentPartyIDSource is a non-required field for NoUndlyInstrumentParties. - UnderlyingInstrumentPartyIDSource *string `fix:"1060"` - //UnderlyingInstrumentPartyRole is a non-required field for NoUndlyInstrumentParties. - UnderlyingInstrumentPartyRole *int `fix:"1061"` - //UndlyInstrumentPtysSubGrp Component - undlyinstrumentptyssubgrp.UndlyInstrumentPtysSubGrp -} - //UnderlyingInstrument is a fix50sp2 Component type UnderlyingInstrument struct { //UnderlyingSymbol is a non-required field for UnderlyingInstrument. @@ -42,8 +16,8 @@ type UnderlyingInstrument struct { UnderlyingSecurityID *string `fix:"309"` //UnderlyingSecurityIDSource is a non-required field for UnderlyingInstrument. UnderlyingSecurityIDSource *string `fix:"305"` - //NoUnderlyingSecurityAltID is a non-required field for UnderlyingInstrument. - NoUnderlyingSecurityAltID []NoUnderlyingSecurityAltID `fix:"457,omitempty"` + //UndSecAltIDGrp Component + undsecaltidgrp.UndSecAltIDGrp //UnderlyingProduct is a non-required field for UnderlyingInstrument. UnderlyingProduct *int `fix:"462"` //UnderlyingCFICode is a non-required field for UnderlyingInstrument. @@ -124,8 +98,8 @@ type UnderlyingInstrument struct { UnderlyingCurrentValue *float64 `fix:"885"` //UnderlyingEndValue is a non-required field for UnderlyingInstrument. UnderlyingEndValue *float64 `fix:"886"` - //NoUnderlyingStips is a non-required field for UnderlyingInstrument. - NoUnderlyingStips []NoUnderlyingStips `fix:"887,omitempty"` + //UnderlyingStipulations Component + underlyingstipulations.UnderlyingStipulations //UnderlyingAllocationPercent is a non-required field for UnderlyingInstrument. UnderlyingAllocationPercent *float64 `fix:"972"` //UnderlyingSettlementType is a non-required field for UnderlyingInstrument. @@ -140,8 +114,8 @@ type UnderlyingInstrument struct { UnderlyingTimeUnit *string `fix:"1000"` //UnderlyingCapValue is a non-required field for UnderlyingInstrument. UnderlyingCapValue *float64 `fix:"1038"` - //NoUndlyInstrumentParties is a non-required field for UnderlyingInstrument. - NoUndlyInstrumentParties []NoUndlyInstrumentParties `fix:"1058,omitempty"` + //UndlyInstrumentParties Component + undlyinstrumentparties.UndlyInstrumentParties //UnderlyingSettlMethod is a non-required field for UnderlyingInstrument. UnderlyingSettlMethod *string `fix:"1039"` //UnderlyingAdjustedQuantity is a non-required field for UnderlyingInstrument. @@ -186,9 +160,6 @@ func (m *UnderlyingInstrument) SetUnderlyingSecurityID(v string) { m.UnderlyingS func (m *UnderlyingInstrument) SetUnderlyingSecurityIDSource(v string) { m.UnderlyingSecurityIDSource = &v } -func (m *UnderlyingInstrument) SetNoUnderlyingSecurityAltID(v []NoUnderlyingSecurityAltID) { - m.NoUnderlyingSecurityAltID = v -} func (m *UnderlyingInstrument) SetUnderlyingProduct(v int) { m.UnderlyingProduct = &v } func (m *UnderlyingInstrument) SetUnderlyingCFICode(v string) { m.UnderlyingCFICode = &v } func (m *UnderlyingInstrument) SetUnderlyingSecurityType(v string) { m.UnderlyingSecurityType = &v } @@ -237,17 +208,16 @@ func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDescLen(v int) { func (m *UnderlyingInstrument) SetEncodedUnderlyingSecurityDesc(v string) { m.EncodedUnderlyingSecurityDesc = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } -func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } -func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } -func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } -func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } -func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } -func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } -func (m *UnderlyingInstrument) SetNoUnderlyingStips(v []NoUnderlyingStips) { m.NoUnderlyingStips = v } +func (m *UnderlyingInstrument) SetUnderlyingCPProgram(v string) { m.UnderlyingCPProgram = &v } +func (m *UnderlyingInstrument) SetUnderlyingCPRegType(v string) { m.UnderlyingCPRegType = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrency(v string) { m.UnderlyingCurrency = &v } +func (m *UnderlyingInstrument) SetUnderlyingQty(v float64) { m.UnderlyingQty = &v } +func (m *UnderlyingInstrument) SetUnderlyingPx(v float64) { m.UnderlyingPx = &v } +func (m *UnderlyingInstrument) SetUnderlyingDirtyPrice(v float64) { m.UnderlyingDirtyPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndPrice(v float64) { m.UnderlyingEndPrice = &v } +func (m *UnderlyingInstrument) SetUnderlyingStartValue(v float64) { m.UnderlyingStartValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingCurrentValue(v float64) { m.UnderlyingCurrentValue = &v } +func (m *UnderlyingInstrument) SetUnderlyingEndValue(v float64) { m.UnderlyingEndValue = &v } func (m *UnderlyingInstrument) SetUnderlyingAllocationPercent(v float64) { m.UnderlyingAllocationPercent = &v } @@ -257,10 +227,7 @@ func (m *UnderlyingInstrument) SetUnderlyingCashType(v string) { m.Underlyi func (m *UnderlyingInstrument) SetUnderlyingUnitOfMeasure(v string) { m.UnderlyingUnitOfMeasure = &v } func (m *UnderlyingInstrument) SetUnderlyingTimeUnit(v string) { m.UnderlyingTimeUnit = &v } func (m *UnderlyingInstrument) SetUnderlyingCapValue(v float64) { m.UnderlyingCapValue = &v } -func (m *UnderlyingInstrument) SetNoUndlyInstrumentParties(v []NoUndlyInstrumentParties) { - m.NoUndlyInstrumentParties = v -} -func (m *UnderlyingInstrument) SetUnderlyingSettlMethod(v string) { m.UnderlyingSettlMethod = &v } +func (m *UnderlyingInstrument) SetUnderlyingSettlMethod(v string) { m.UnderlyingSettlMethod = &v } func (m *UnderlyingInstrument) SetUnderlyingAdjustedQuantity(v float64) { m.UnderlyingAdjustedQuantity = &v } diff --git a/fix50sp2/underlyingleginstrument/UnderlyingLegInstrument.go b/fix50sp2/underlyingleginstrument/UnderlyingLegInstrument.go index d554fb94e..914eddefd 100644 --- a/fix50sp2/underlyingleginstrument/UnderlyingLegInstrument.go +++ b/fix50sp2/underlyingleginstrument/UnderlyingLegInstrument.go @@ -1,12 +1,8 @@ package underlyingleginstrument -//NoUnderlyingLegSecurityAltID is a repeating group in UnderlyingLegInstrument -type NoUnderlyingLegSecurityAltID struct { - //UnderlyingLegSecurityAltID is a non-required field for NoUnderlyingLegSecurityAltID. - UnderlyingLegSecurityAltID *string `fix:"1335"` - //UnderlyingLegSecurityAltIDSource is a non-required field for NoUnderlyingLegSecurityAltID. - UnderlyingLegSecurityAltIDSource *string `fix:"1336"` -} +import ( + "github.com/quickfixgo/quickfix/fix50sp2/underlyinglegsecurityaltidgrp" +) //UnderlyingLegInstrument is a fix50sp2 Component type UnderlyingLegInstrument struct { @@ -18,8 +14,8 @@ type UnderlyingLegInstrument struct { UnderlyingLegSecurityID *string `fix:"1332"` //UnderlyingLegSecurityIDSource is a non-required field for UnderlyingLegInstrument. UnderlyingLegSecurityIDSource *string `fix:"1333"` - //NoUnderlyingLegSecurityAltID is a non-required field for UnderlyingLegInstrument. - NoUnderlyingLegSecurityAltID []NoUnderlyingLegSecurityAltID `fix:"1334,omitempty"` + //UnderlyingLegSecurityAltIDGrp Component + underlyinglegsecurityaltidgrp.UnderlyingLegSecurityAltIDGrp //UnderlyingLegCFICode is a non-required field for UnderlyingLegInstrument. UnderlyingLegCFICode *string `fix:"1344"` //UnderlyingLegSecurityType is a non-required field for UnderlyingLegInstrument. @@ -50,9 +46,6 @@ func (m *UnderlyingLegInstrument) SetUnderlyingLegSecurityID(v string) { m.Under func (m *UnderlyingLegInstrument) SetUnderlyingLegSecurityIDSource(v string) { m.UnderlyingLegSecurityIDSource = &v } -func (m *UnderlyingLegInstrument) SetNoUnderlyingLegSecurityAltID(v []NoUnderlyingLegSecurityAltID) { - m.NoUnderlyingLegSecurityAltID = v -} func (m *UnderlyingLegInstrument) SetUnderlyingLegCFICode(v string) { m.UnderlyingLegCFICode = &v } func (m *UnderlyingLegInstrument) SetUnderlyingLegSecurityType(v string) { m.UnderlyingLegSecurityType = &v diff --git a/validation.go b/validation.go index a21e0561c..89c936a5e 100644 --- a/validation.go +++ b/validation.go @@ -167,7 +167,7 @@ func validateVisitGroupField(fieldDef *datadictionary.FieldDef, fieldStack []tag return fieldStack, err } } else { - if childDefs[0].Required { + if childDefs[0].Required() { return fieldStack, requiredTagMissing(Tag(childDefs[0].Tag)) } } diff --git a/validation_test.go b/validation_test.go index b818e58b6..c2158e36e 100644 --- a/validation_test.go +++ b/validation_test.go @@ -1,9 +1,10 @@ package quickfix import ( - "github.com/quickfixgo/quickfix/datadictionary" "testing" "time" + + "github.com/quickfixgo/quickfix/datadictionary" ) type validateTest struct { @@ -364,7 +365,7 @@ func tcFloatValidation() validateTest { } func TestValidateVisitField(t *testing.T) { - fieldType := &datadictionary.FieldType{Name: "myfield", Tag: 11, Type: "STRING"} + fieldType := datadictionary.NewFieldType("myfield", 11, "STRING") fieldDef := &datadictionary.FieldDef{FieldType: fieldType} TagValues := make([]tagValue, 1) @@ -380,13 +381,13 @@ func TestValidateVisitField(t *testing.T) { } func TestValidateVisitFieldGroup(t *testing.T) { - fieldType1 := &datadictionary.FieldType{Name: "myfield", Tag: 2, Type: "STRING"} + fieldType1 := datadictionary.NewFieldType("myfield", 2, "STRING") fieldDef1 := &datadictionary.FieldDef{FieldType: fieldType1, ChildFields: []*datadictionary.FieldDef{}} - fieldType2 := &datadictionary.FieldType{Name: "myfield", Tag: 3, Type: "STRING"} + fieldType2 := datadictionary.NewFieldType("myfield", 3, "STRING") fieldDef2 := &datadictionary.FieldDef{FieldType: fieldType2, ChildFields: []*datadictionary.FieldDef{}} - groupFieldType := &datadictionary.FieldType{Name: "mygroupfield", Tag: 1, Type: "INT"} + groupFieldType := datadictionary.NewFieldType("mygroupfield", 1, "INT") groupFieldDef := &datadictionary.FieldDef{FieldType: groupFieldType, ChildFields: []*datadictionary.FieldDef{fieldDef1, fieldDef2}} var repField1 tagValue