mirror of
https://github.com/aclindsa/ofxgo.git
synced 2024-11-22 11:30:05 -05:00
Make Decode*MessageSet functions private to the library
These don't need to be exposed and clutter the auto-generated documentation
This commit is contained in:
parent
896bd55327
commit
27a88ca703
@ -151,7 +151,7 @@ func (sr StatementResponse) Valid() (bool, error) {
|
|||||||
return true, nil
|
return true, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func DecodeBankingMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
func decodeBankingMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
||||||
var msgs []Message
|
var msgs []Message
|
||||||
for {
|
for {
|
||||||
tok, err := nextNonWhitespaceToken(d)
|
tok, err := nextNonWhitespaceToken(d)
|
||||||
|
@ -58,7 +58,7 @@ func (sr CCStatementResponse) Valid() (bool, error) {
|
|||||||
return true, nil
|
return true, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func DecodeCCMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
func decodeCCMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
||||||
var msgs []Message
|
var msgs []Message
|
||||||
for {
|
for {
|
||||||
tok, err := nextNonWhitespaceToken(d)
|
tok, err := nextNonWhitespaceToken(d)
|
||||||
|
@ -713,7 +713,7 @@ func (sr InvStatementResponse) Valid() (bool, error) {
|
|||||||
return true, nil
|
return true, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func DecodeInvestmentsMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
func decodeInvestmentsMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
||||||
var msgs []Message
|
var msgs []Message
|
||||||
for {
|
for {
|
||||||
tok, err := nextNonWhitespaceToken(d)
|
tok, err := nextNonWhitespaceToken(d)
|
||||||
|
@ -126,7 +126,7 @@ func (pr ProfileResponse) Valid() (bool, error) {
|
|||||||
return true, nil
|
return true, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func DecodeProfileMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
func decodeProfileMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
||||||
var msgs []Message
|
var msgs []Message
|
||||||
for {
|
for {
|
||||||
tok, err := nextNonWhitespaceToken(d)
|
tok, err := nextNonWhitespaceToken(d)
|
||||||
|
12
response.go
12
response.go
@ -258,26 +258,26 @@ func ParseResponse(reader io.Reader) (*Response, error) {
|
|||||||
// TODO decode other types
|
// TODO decode other types
|
||||||
switch start.Name.Local {
|
switch start.Name.Local {
|
||||||
case "SIGNUPMSGSRSV1":
|
case "SIGNUPMSGSRSV1":
|
||||||
msgs, err := DecodeSignupMessageSet(decoder, start)
|
msgs, err := decodeSignupMessageSet(decoder, start)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
or.Signup = msgs
|
or.Signup = msgs
|
||||||
case "BANKMSGSRSV1":
|
case "BANKMSGSRSV1":
|
||||||
msgs, err := DecodeBankingMessageSet(decoder, start)
|
msgs, err := decodeBankingMessageSet(decoder, start)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
or.Banking = msgs
|
or.Banking = msgs
|
||||||
case "CREDITCARDMSGSRSV1":
|
case "CREDITCARDMSGSRSV1":
|
||||||
msgs, err := DecodeCCMessageSet(decoder, start)
|
msgs, err := decodeCCMessageSet(decoder, start)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
or.CreditCards = msgs
|
or.CreditCards = msgs
|
||||||
//case "LOANMSGSRSV1":
|
//case "LOANMSGSRSV1":
|
||||||
case "INVSTMTMSGSRSV1":
|
case "INVSTMTMSGSRSV1":
|
||||||
msgs, err := DecodeInvestmentsMessageSet(decoder, start)
|
msgs, err := decodeInvestmentsMessageSet(decoder, start)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -287,7 +287,7 @@ func ParseResponse(reader io.Reader) (*Response, error) {
|
|||||||
//case "BILLPAYMSGSRSV1":
|
//case "BILLPAYMSGSRSV1":
|
||||||
//case "EMAILMSGSRSV1":
|
//case "EMAILMSGSRSV1":
|
||||||
case "SECLISTMSGSRSV1":
|
case "SECLISTMSGSRSV1":
|
||||||
msgs, err := DecodeSecuritiesMessageSet(decoder, start)
|
msgs, err := decodeSecuritiesMessageSet(decoder, start)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -295,7 +295,7 @@ func ParseResponse(reader io.Reader) (*Response, error) {
|
|||||||
//case "PRESDIRMSGSRSV1":
|
//case "PRESDIRMSGSRSV1":
|
||||||
//case "PRESDLVMSGSRSV1":
|
//case "PRESDLVMSGSRSV1":
|
||||||
case "PROFMSGSRSV1":
|
case "PROFMSGSRSV1":
|
||||||
msgs, err := DecodeProfileMessageSet(decoder, start)
|
msgs, err := decodeProfileMessageSet(decoder, start)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -227,7 +227,7 @@ func (r *SecurityList) UnmarshalXML(d *xml.Decoder, start xml.StartElement) erro
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func DecodeSecuritiesMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
func decodeSecuritiesMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
||||||
var msgs []Message
|
var msgs []Message
|
||||||
for {
|
for {
|
||||||
tok, err := nextNonWhitespaceToken(d)
|
tok, err := nextNonWhitespaceToken(d)
|
||||||
|
@ -122,7 +122,7 @@ func (air AcctInfoResponse) Valid() (bool, error) {
|
|||||||
return true, nil
|
return true, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func DecodeSignupMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
func decodeSignupMessageSet(d *xml.Decoder, start xml.StartElement) ([]Message, error) {
|
||||||
var msgs []Message
|
var msgs []Message
|
||||||
for {
|
for {
|
||||||
tok, err := nextNonWhitespaceToken(d)
|
tok, err := nextNonWhitespaceToken(d)
|
||||||
|
Loading…
Reference in New Issue
Block a user