Documentation ¶
Index ¶
- Constants
- Variables
- func DefaultFormVersion(formType string) (string, error)
- func EqipClient(env Settings) (*eqip.Client, error)
- func IsDatabaseErrorNotFound(err error) bool
- type Account
- func (entity *Account) BasicAuthentication(context DatabaseService, password string) error
- func (entity *Account) CanKickback() bool
- func (entity *Account) CanSubmit() bool
- func (entity *Account) Delete(context DatabaseService, account int) (int, error)
- func (entity *Account) Find(context DatabaseService) error
- func (entity *Account) FindByExternalID(context DatabaseService) error
- func (entity *Account) FormTypeIsKnown() bool
- func (entity *Account) Get(context DatabaseService, account int) (int, error)
- func (entity *Account) GetID() int
- func (entity *Account) Kickback() bool
- func (entity *Account) Save(context DatabaseService, account int) (int, error)
- func (entity *Account) SetID(id int)
- func (entity *Account) Submit() bool
- func (entity *Account) Unsubmit()
- type AdditionalComments
- type Application
- func (a *Application) ClearNoBranches() error
- func (a *Application) EqipRequest(env Settings, xmlContent string) (*eqip.ImportRequest, error)
- func (a Application) FormType() string
- func (a Application) FormVersion() string
- func (a *Application) Hash() (string, error)
- func (a Application) MarshalJSON() ([]byte, error)
- func (a Application) Section(identifier string) Section
- func (a *Application) SetSection(section Section)
- func (a *Application) UnmarshalJSON(bytes []byte) error
- type ArchivalPdf
- type Attachment
- type BasicAuthMembership
- func (entity *BasicAuthMembership) Delete(context DatabaseService, account int) (int, error)
- func (entity *BasicAuthMembership) Find(context DatabaseService) error
- func (entity *BasicAuthMembership) Get(context DatabaseService, account int) (int, error)
- func (entity *BasicAuthMembership) GetID() int
- func (entity *BasicAuthMembership) HashPassword(password string) error
- func (entity *BasicAuthMembership) PasswordMatch(password string) bool
- func (entity *BasicAuthMembership) Save(context DatabaseService, account int) (int, error)
- func (entity *BasicAuthMembership) SetID(id int)
- type Benefit
- type Branch
- type Checkbox
- type CheckboxGroup
- type CitizenshipMultiple
- type CitizenshipPassports
- type CitizenshipStatus
- type CivilUnion
- type ClearanceLevel
- type CoOwners
- type Collection
- type CollectionItem
- func (ci CollectionItem) Each(action func(string, string, Entity, error) error) error
- func (ci CollectionItem) GetItemValue(key string) (Entity, error)
- func (ci CollectionItem) MarshalJSON() ([]byte, error)
- func (ci *CollectionItem) SetItemValue(key string, value Entity) error
- func (ci *CollectionItem) UnmarshalJSON(bytes []byte) error
- type Contacts
- type Country
- type DatabaseErrorNotFound
- type DatabaseService
- type DateControl
- type DateRange
- type Email
- type EmploymentActivity
- type Entity
- type ErrFieldInvalid
- type ErrFieldRequired
- type ErrInvalidLocation
- type ErrorStack
- type ErrorStackResults
- type FinancialBankruptcy
- type FinancialCard
- type FinancialCredit
- type FinancialDelinquent
- type FinancialGambling
- type FinancialNonpayment
- type FinancialTaxes
- type ForeignActivitiesBenefits
- type ForeignActivitiesDirect
- type ForeignActivitiesIndirect
- type ForeignActivitiesRealEstate
- type ForeignActivitiesSupport
- type ForeignBornDocument
- type ForeignBusinessAdvice
- type ForeignBusinessConferences
- type ForeignBusinessContact
- type ForeignBusinessEmployment
- type ForeignBusinessFamily
- type ForeignBusinessPolitical
- type ForeignBusinessSponsorship
- type ForeignBusinessVentures
- type ForeignBusinessVoting
- type ForeignContacts
- type ForeignPassport
- type ForeignTravel
- type GeocodeResult
- type GeocodeResults
- type GeocodeValues
- type Geocoder
- type Height
- type HistoryEducation
- type HistoryEmployment
- type HistoryFederal
- type HistoryResidence
- type IdentificationBirthDate
- type IdentificationBirthPlace
- type IdentificationContacts
- type IdentificationName
- type IdentificationOtherNames
- type IdentificationPhysical
- type IdentificationSSN
- type LegalAssociationsActivitiesToOverthrow
- type LegalAssociationsAdvocating
- type LegalAssociationsEngagedInTerrorism
- type LegalAssociationsMembershipOverthrow
- type LegalAssociationsMembershipViolence
- type LegalAssociationsTerrorismAssociation
- type LegalAssociationsTerroristOrganization
- type LegalCourt
- type LegalInvestigationsDebarred
- type LegalInvestigationsHistory
- type LegalInvestigationsRevoked
- type LegalPoliceAdditionalOffenses
- type LegalPoliceDomesticViolence
- type LegalPoliceOffenses
- type LegalTechnologyManipulating
- type LegalTechnologyUnauthorized
- type LegalTechnologyUnlawful
- type Location
- type LogFields
- type LogService
- type Marshaller
- type Migration
- type MilitaryDisciplinary
- type MilitaryForeign
- type MilitaryHistory
- type MilitarySelective
- type Name
- type NotApplicable
- type Number
- type Payload
- type PdfService
- type PhysicalAddress
- type PsychologicalCompetence
- type PsychologicalConsultations
- type PsychologicalDiagnoses
- type PsychologicalExisting
- type PsychologicalHospitalizations
- type Radio
- type ReasonLeft
- type Rejector
- type RelationshipsCohabitants
- type RelationshipsMarital
- type RelationshipsPeople
- type RelationshipsRelatives
- type SAMLResponseType
- type SSN
- type SamlService
- type Section
- type SectionInformation
- type Sentence
- type Serializer
- type Session
- type SessionService
- type Settings
- type Signature
- type StorageService
- type Submission
- type SubmissionAdditionalComments
- type SubmissionAttachments
- type SubmissionCredit
- type SubmissionGeneral
- type SubmissionMedical
- type SubstanceAlcoholAdditional
- type SubstanceAlcoholNegative
- type SubstanceAlcoholOrdered
- type SubstanceAlcoholVoluntary
- type SubstanceDrugClearance
- type SubstanceDrugMisuse
- type SubstanceDrugOrdered
- type SubstanceDrugPublicSafety
- type SubstanceDrugPurchase
- type SubstanceDrugUsage
- type SubstanceDrugVoluntary
- type Supervisor
- type Telephone
- type Text
- type Textarea
- type Transmission
- type Treatment
- type ValidationResult
- type XMLService
Constants ¶
const ( // StatusIncomplete indicates that the submission is INCOMPLETE StatusIncomplete = "INCOMPLETE" // StatusSubmitted indicates that the submission is SUBMITTED StatusSubmitted = "SUBMITTED" // StatusKickback indicates that the submission is KICKBACK StatusKickback = "KICKBACK" )
const ( Certification = "CER" MedicalRelease = "MEL" GeneralRelease = "REL" CreditRelease = "FCR" )
Attachment document types (dervied from e-QIP identifiers)
const ( BasicAuthAudience = "Basic" SingleSignOnAudience = "SSO" )
Audience types used with Javascript Web Tokens.
BasicAuthAudience is used when basic authentication is used. SingleSignOnAudience is used when SAML/OAuth authentication is used.
const ( LayoutAddress = "Address" LayoutBirthPlace = "Birthplace" LayoutBirthPlaceWithoutCounty = "Birthplace without County" LayoutCountry = "Country" LayoutUSCityStateInternationalCity = "US City, State, International city" LayoutUSCityStateInternationalCityCountry = "US City, State, International city country" LayoutState = "State" LayoutCityState = "City, State" LayoutStreetCityCountry = "Street, City, Country" LayoutCityCountry = "City, Country" LayoutUSCityStateZipcodeInternationalCity = "US City, State, Zipcode International city" LayoutCityStateCountry = "City, State, Country" LayoutUSAddress = "US Address" LayoutStreetCity = "Street, City" LayoutOffense = "Offense" )
Different potential layouts used by the frontend. File: /src/components/Form/Location/Layouts.js
const ( // Country elements with CountriesNoUS type LayoutBirthPlaceWithoutCountyNoUS = "Birthplace without County CountriesNoUS" LayoutBirthPlaceNoUS = "Birthplace CountriesNoUS" // APOFPO elements LayoutMilitaryAddress = "Military Address" LayoutPhysicalDomestic = "PhysicalDomestic" LayoutPhysicalInternational = "PhysicalInternational" )
Special layout flags for e-QIP integration for...
const ( AccountLocked = "The account is currently locked" AccountUpdateError = "Not able to update account information" StatusError = "Unable to determine the status of the application" BasicAuthNotImplemented = "Basic authentication is not implemented" BasicAuthAttemptDenied = "An attempt for basic authentication was denied" BasicAuthError = "Failed to decode JSON for basic authentication" BasicAuthInvalid = "Basic authentication invalid" BasicAuthMissingPassword = "Basic authentication failed because missing a password" BasicAuthMissingUsername = "Basic authentication failed because missing a username" BasicLogoutFailed = "Failed to logout user" SessionExpired = "Auth failed because of an expired session" SessionDoesNotExist = "Auth failed because of an invalid session" SessionUnexpectedError = "An unexpected error occured while checking the session." CSRFTokenMissing = "The state modifying request is missing a CSRF Token" CSRFTokenInvalid = "The state modifying request has an invalid CSRF Token" RequestIsMissingSessionCookie = "Unauthorized: Request is missing a session cookie" CORSDenied = "CORS request denied" CookieDomainNotSet = "Cookie Domain is not set" EntityError = "Error getting entity data" EntitySaveError = "Error saving entity data" FormDecodingError = "Error serializing form" HashingFailure = "Error calculating hash" MiddlewareError = "Middleware has thrown an error" MigrationUnsupported = "Database migrations are not automated for Windows. Please manually execute the migrations." NoAccount = "Unable to retrieve account" NoAuthorizationToken = "No authorization token header found" NoUsername = "Unable to retrieve account because no username was provided" PayloadDeserializeError = "Failed to deserialize payload" PayloadEmpty = "Payload not provided" PayloadEntityError = "Error converting payload into valid entity" PayloadInvalid = "Payload is invalid" PayloadMissingType = "Payload is missing a type" InvalidValidation = "The validation api is only for validating locations with the USPS" PdfError = "Error generating archival signature PDFs" RetrievingAccount = "Retrieving account" SamlNotImplemented = "SAML is not implemented" SamlAttemptDenied = "An attempt for SAML authentication was denied" SamlNotEnabled = "SAML is not enabled" SamlSLONotEnabled = "SAML SLO is not enabled" SamlSLOLogoutFailed = "Failed to SAML logout user" SamlFormError = "SAML response form value missing" SamlIdentifierMissing = "SAML attribute identifier missing" SamlInvalid = "SAML response invalid" SamlParseError = "Error parsing SAML response" SamlRequestError = "Error creating SAML authentication request" SamlRequestURLError = "Error creating SAML authentication request URL" SamlVerificationError = "Error verifying SAML response" SamlSLORequestGeneration = "Error generating SAML SLO Request" SamlSLOMissingSessionIndex = "Missing Session Index from AuthNResponse. WSO2 may be mis-configured" USPSDecodeError = "Error decoding USPS geocoding response" USPSKnownErrorCode = "USPS known error received" USPSMissingKey = "USPS API key has not been set" USPSRequestError = "Error executing USPS geocoding request" USPSUnknownErrorCode = "USPS known error received" WarnFailedMigration = "Failed to migrate database" WebserviceMissingURL = "Missing endpoint URL for web service" WebserviceMissingKey = "Missing private key for web service" WebserviceMissingCallerInfoAgencyID = "Missing Caller Info Agency ID" WebserviceMissingCallerInfoAgencySSN = "Missing Caller Info Agency SSN" WebserviceMissingCallerInfoAgencyPseudoSSN = "Missing Caller Info Agency Pseudo SSN" WebserviceCannotGenerateInboundXML = "Unable to generate XML from Form Application Data" WebserviceCannotGetApplicationData = "Unable to retrieve Form Application Data" WebserviceMissingAgencyID = "Missing Agency ID" WebserviceErrorCreatingImportRequest = "Unable to create import request" TransmissionError = "Error transmitting package" TransmissionStorageError = "Failed to store transmission record" AttachmentsNotImplemented = "Attachments is not implemented" AttachmentDenied = "An attempt for attachments was denied" AttachmentNoFile = "No attachment file found in multipart form data" AttachmentCopyBufferError = "Could not copy file buffer" AttachmentNotSaved = "Attachment file failed to save in persistent storage" AttachmentNotDeleted = "Attachment file failed to delete" AttachmentNoID = "No identifier for attachment provided" AttachmentNotFound = "Attachment file not found" AttachmentSizeMismatch = "Attachment file size mismatch" AttachmentSizeExceeded = "Attachment file size exceeded maximum allowed" AttachmentTypeNotAllowed = "Attachment file type not allowed" )
Warning messages
const ( BasicAuthValid = "Basic authentication validated" GeneratingPackage = "Generating package for transmission" LoggedOut = "Logged out" PurgeAccountData = "Purging account data" SamlValid = "SAML authentication validated" SessionCreated = "New Session Created" SessionDestroyed = "Session Was Destroyed" SessionRefreshed = "Session was refreshed with the refresh API" SessionConcurrentLogin = "User logged in again with a concurrent active session" StartingServer = "Starting server" StartingServerTLS = "Starting server with HTTPS/TLS" StoppingServer = "Stopping server" TransmissionRecorded = "Transmission recorded" TransmissionStarted = "Transmission began" TransmissionStopped = "Transmission ended" CORSIgnored = "CORS ignoring OPTION method" WebRequest = "Web server request received" AttachmentSaved = "Attachment saved" AttachmentDeleted = "Attachment deleted" AttachmentDownloaded = "Attachment downloaded" CacheHeaders = "Applying headers for caching" )
Informative messages
const ( // NodeEnv Sets the Node environment to configure the application for a specific uses: // // - `test`: used with unit testing and code coverage // - `development`: for use while developing the application // - `staging`: environment for various usability tests prior to releasing to production // - `production`: minify and optimize all possible assets for optimal use // // Target: Front-end (web) // Default: `development` // Values: `test` | `development` | `staging` | `production` NodeEnv = "NODE_ENV" // GolangEnv Sets the Go environment to configure the application for specific uses: // // - `test`: used with unit testing and code coverage // - `development`: for use while developing the application // - `staging`: environment for various usability tests prior to releasing to production // - `production`: compiled for production use only minimum required assets (does **not** include test accounts) // // Target: Back-end (api) // Default: `development` // Values: `test` | `development` | `staging` | `production` GolangEnv = "GOLANG_ENV" // LogLevel Log level for the back-end API. The default source for logging will be standard outputs (`stdout` and `stderr`). // // Target: Back-end (api) // Default: `warning` // Values: `debug` | `info` | `warning` | `error` | `fatal` | `panic` LogLevel = "LOG_LEVEL" // LogFile Path to the local file system log file. // // Logging to file may be used in conjunction with other logging sources. // // Target: Back-end (api) // Default: *not enabled* LogFile = "LOG_FILE" // LogDirectory Path to the local file system log file. // // Logging to file may be used in conjunction with other logging sources. // // Target: Back-end (api) // Default: *not enabled* LogDirectory = "LOG_DIRECTORY" // LogSyslog Connection string for a `syslog` server such as `udp://logserver:514`. Both TCP and UDP are supported. // // Logging to `syslog` may be used in conjunction with other logging sources. // // Target: Back-end (api) // Default: *not enabled* // Values: `{protocol}://{host}:{port}` LogSyslog = "LOG_SYSLOG" // LogSyslogCert Providing a path to the PEM certificate will convert all `syslog` communication to use TLS. Only TCP + TLS is supported making the connection string `tcp://logserver:514`. // // Logging to `syslog` may be used in conjunction with other logging sources. // // Target: Back-end (api) // Default: *not enabled* LogSyslogCert = "LOG_SYSLOG_CERT" // SessionTimeout Session timeout in minutes. Periods of inactivity falling outside of the threshold will be considered invalid and are required to be re-authenticated. // // Target: Back-end (api) // Default: `15` SessionTimeout = "SESSION_TIMEOUT" // APIRedirect Front-end URL for the back-end to redirect responses to. If this value is not set it will redirect to the same server host but on port 80. // // Target: Back-end (api) // Default: `{server_protocol}://{server_host}` APIRedirect = "API_REDIRECT" // APIBaseURL Back-end URL for the front-end to direct requests to. // // Target: Front-end (web), Back-end (api) // Default: `{server_protocol}://{server_host}:{server_port}/api` APIBaseURL = "API_BASE_URL" // Port Port to use for back-end API. // // Target: Back-end (api) // Default: `3000` Port = "PORT" // HashRouting Flag to enable hash routing. This should only be used in scenarios where push state is not an option. // // Target: Front-end (web) // Default: False: *empty* // Values: True: `1`, False: *empty* HashRouting = "HASH_ROUTING" // DbMigrationTarget Target a specific database migration step for example, `20180212130825_account_lock.sql`. By specifying a target then when migrations are ran it will try to step down **or** up until the target is reached. By not providing a value migrations will always attempt to go to the latest version. // // Target: Back-end (api) // Default: *not enabled* DbMigrationTarget = "DB_MIGRATION_TARGET" // DatabaseURI PostgreSQL database connection string. If a value is set do no set other database connection information. // // Target: Back-end (api) // Default: *none* // Values: `postgres://{db-username}:{db-password}@{db-host}:5432/{db-name}` DatabaseURI = "DATABASE_URI" // DatabaseUser PostgreSQL database user name. // // Target: Back-end (api) // Default: `postgres` DatabaseUser = "DATABASE_USER" // DatabasePassword PostgreSQL database password. // // Target: Back-end (api) // Default: *none* DatabasePassword = "DATABASE_PASSWORD" // DatabaseName PostgreSQL database instance name. // // Target: Back-end (api) // Default: `postgres` DatabaseName = "DATABASE_NAME" // DatabaseSSLMode The PostgreSQL sslmode to use to connect to the db // // Target: Back-end (api) // Default: `require` DatabaseSSLMode = "DATABASE_SSLMODE" // TestDatabaseName PostgreSQL database instance name for tests // // Target: Back-end (api) // Default: `eapp_test` TestDatabaseName = "TEST_DATABASE_NAME" // DatabaseHost PostgreSQL database host name and port. // // Target: Back-end (api) // Default: `localhost:5432` DatabaseHost = "DATABASE_HOST" // CORSAllowed Whitelist of address(es) for cross-origin resource sharing (CORS). CORS restricts resources (e.g. fonts, scripts, images) on a web page to be requested from another domain outside of the domain from which it is served. // // Examples // // | Type | Example | // | ------------------ | ---------------------------------- | // | explicit | http://localhost | // | multiple | http://localhost;https://test\.com | // | wildcard | * | // | regular expression | https?://localhost | // // Target: Back-end (api) // Default: *empty* CORSAllowed = "CORS_ALLOWED" // CORSMaxAge The number of seconds browsers should cache preflight requests. // // Target: Back-end (api) // Default: `600` CORSMaxAge = "CORS_MAX_AGE" // FlushStorage Flag to enable flushing of persisted information for an account during the logon process. // // Target: Back-end (api) // Default: False: *empty* // Values: True: `1`, False: *empty* FlushStorage = "FLUSH_STORAGE" // UspsAPIKey United States Postal Service (USPS) API key for address validation. // // Target: Back-end (api) // Default: *not enabled* UspsAPIKey = "USPS_API_API_KEY" // CSRFSecret Random tokens used for CSRF digitally signed using a secret random key of at least 256-bits. // // Target: Back-end (api) // Default: *none* CSRFSecret = "CSRF_SECRET" // BasicEnabled Flag to enable basic username and password authentication. // // Target: Front-end (web), Back-end (api) // Default: False: *empty* // Values: True: `1`, False: *empty* BasicEnabled = "BASIC_ENABLED" // SamlEnabled Flag to enable SAML authentication. // // Target: Front-end (web), Back-end (api) // Default: False: *empty* // Values: True: `1`, False: *empty* SamlEnabled = "SAML_ENABLED" // SamlSloEnabled Flag to enable SAML single logout. // // Target: Front-end (web), Back-end (api) // Default: False: *empty* // Values: True: `1`, False: *empty* SamlSloEnabled = "SAML_SLO_ENABLED" // SamlPublicCert File path (absolute or relative) to SAML public certificate. // // Target: Back-end (api) // Default: *not enabled* SamlPublicCert = "SAML_PUBLIC_CERT" // SamlPrivateCert File path (absolute or relative) to SAML private certificate. // // Target: Back-end (api) // Default: *not enabled* SamlPrivateCert = "SAML_PRIVATE_CERT" // SamlIdpSsoURL Endpoint to SAML 2.0 Single Sign-On (SSO) identity provider. The client will be redirected to this URL to complete the authentication process. This value will be provided by the IdAM configuration settings. // // Target: Back-end (api) // Default: *not enabled* SamlIdpSsoURL = "SAML_IDP_SSO_URL" // SamlIdpSsoDescURL The identity provider's issuer URL. This value will be provided by the IdAM configuration settings. // // Target: Back-end (api) // Default: *not enabled* SamlIdpSsoDescURL = "SAML_IDP_SSO_DESC_URL" // SamlIdpPublicCert File path (absolute or relative) to identity data provider's public certificate (X.509 PEM) used to verify the authentication response signature. This certificate will be provided by the IdAM solution. // // Target: Back-end (api) // Default: *not enabled* SamlIdpPublicCert = "SAML_IDP_PUBLIC_CERT" // SamlSignRequest Flag to enable signing of SAML 2.0 requests. // // Target: Back-end (api) // Default: False: *empty* // Values: True: `1`, False: *empty* SamlSignRequest = "SAML_SIGN_REQUEST" // SamlVerifyInsecure Flag to allow insecure validation of SAML 2.0 responses. // // Target: Back-end (api) // Default: False: *empty* // Values: True: `1`, False: *empty* SamlVerifyInsecure = "SAML_VERIFY_INSECURE" // SamlConsumerServiceURL Endpoint for assertion consumer service. After authentication is completed the customer will be redirected to this endpoint for local processes to verify and handle the response. // // Target: Back-end (api) // Default: `{API_BASE_URL}/auth/saml/callback` SamlConsumerServiceURL = "SAML_CONSUMER_SERVICE_URL" // TLSCert File path (absolute or relative) to TLS public certificate (X.509 PEM) certificate for use with the back-end API. // // Target: Back-end (api) // Default: *not enabled* TLSCert = "TLS_CERT" // TLSKey File path (absolute or relative) to TLS private key (X.509 PEM) for use the back-end API. // // Target: Back-end (api) // Default: *not enabled* TLSKey = "TLS_KEY" // WsEnabled Allows requests to be made to the eqip web service. // // Target: Back-end (api) // Default: *not enabled* WsEnabled = "WS_ENABLED" // WsURL The endpoint for the OPM web service used to submit the package for investigation. // // Target: Back-end (api) // Default: *not enabled* WsURL = "WS_URL" // WsKey File path to private certificate key (PKCS#8 DER) used to sign security tokens for the OPM web service. // // Target: Back-end (api) // Default: *not enabled* WsKey = "WS_KEY" // WsCallerinfoAgencyID Provided by OPM representing the caller's agency. // // Target: Back-end (api) // Default: *empty* WsCallerinfoAgencyID = "WS_CALLERINFO_AGENCY_ID" // WsCallerinfoAgencyUserSSN Provided by OPM representing the caller's agency user making the web service call. The value **should not** be a valid SSN. // // Target: Back-end (api) // Default: *empty* WsCallerinfoAgencyUserSSN = "WS_CALLERINFO_AGENCY_USER_SSN" // WsCallerinfoAgencyUserPseudossn Flag representing whether or not the caller has an SSN. // // Target: Back-end (api) // Default: *empty* // Values: True: `1`, False: `0` WsCallerinfoAgencyUserPseudossn = "WS_CALLERINFO_AGENCY_USER_PSEUDOSSN" // WsAgencyID Provided by OPM representing the destination agency. // // Target: Back-end (api) // Default: *empty* WsAgencyID = "WS_AGENCY_ID" // WsAgencyGroupID Provided by OPM representing the destination agency's group. // // Target: Back-end (api) // Default: *empty* WsAgencyGroupID = "WS_AGENCY_GROUP_ID" // AttachmentsEnabled Flag representing whether or not attachments are allowed. // // Target: Front-end (web), Back-end (api) // Default: True: `1` // Values: True: `1`, False: *empty* AttachmentsEnabled = "ATTACHMENTS_ENABLED" // FileMaximumSize Is the maximum file size of an attachment allowed in bytes. // // Target: Front-end (web), Back-end (api) // Default: 5000000 FileMaximumSize = "FILE_MAXIMUM_SIZE" // FileTypes Allowed file types of an attachment. // // Target: Front-end (web), Back-end (api) // Default: ".tiff;.png;.pdf" FileTypes = "FILE_TYPES" // IndentJSON set to indent response JSON. // // Target: Back-end (api) // Default: "" IndentJSON = "INDENT_JSON" // DevDisableSSL controls whether to use a cookie with Secure set to false in development. // Also controls the Strict-Transport-Security header that's set in security_headers.go // // Target: Back-end (api) // Default: "" DevDisableSSL = "DEV_DISABLE_SSL" )
Variables ¶
var ( // ErrPasswordDoesNotMatch is an error when a user inputs an invalid password ErrPasswordDoesNotMatch = errors.New("Password does not match") // ErrAccountDoesNotExist is an error when a users account does not exist ErrAccountDoesNotExist = errors.New("Account does not exist") // ErrDatastoreConnection is an error when a database connection cannot be made ErrDatastoreConnection = errors.New("Unable to connect to datastore") )
var ( // ErrValidSessionNotFound is returned when a valid session is not found ErrValidSessionNotFound = errors.New("Valid session not found") // ErrSessionExpired is returned when the requested session has expired ErrSessionExpired = errors.New("Session is expired") )
var ( // ErrApplicationDoesNotExist is an error when a given application does not exist ErrApplicationDoesNotExist = errors.New("Application does not exist") // ErrApplicationAlreadyExists is an error when a given application does not exist ErrApplicationAlreadyExists = errors.New("Application already exists") // ErrAttachmentDoesNotExist is returned when the requested attchment does not exist. // Note: this could mean that you requested a valid ID but for a different user. ErrAttachmentDoesNotExist = errors.New("Attachment does not exist") )
Functions ¶
func DefaultFormVersion ¶
DefaultFormVersion returns the most recent form version for the given formType
func EqipClient ¶ added in v1.0.12
EqipClient returns a new eqip.Client, configured with the WS_* environment variables.
func IsDatabaseErrorNotFound ¶ added in v1.0.14
IsDatabaseErrorNotFound returns true if the error is a DatabaseErrorNotFound error
Types ¶
type Account ¶ added in v0.5.3
type Account struct { ID int Username string Firstname string Lastname string Token string TokenUsed bool Email sql.NullString Status string FormType string `db:"form_type"` FormVersion string `db:"form_version"` ExternalID string `db:"external_id"` // ExternalID is an identifier used by external systems to id applications }
Account represents a user account
func (*Account) BasicAuthentication ¶ added in v0.5.3
func (entity *Account) BasicAuthentication(context DatabaseService, password string) error
BasicAuthentication checks if the username and password are valid and returns the users account
func (*Account) CanKickback ¶
CanKickback returns wether the account is in a valid state for kickback
func (*Account) Delete ¶ added in v0.5.3
func (entity *Account) Delete(context DatabaseService, account int) (int, error)
Delete the Account entity.
func (*Account) Find ¶ added in v0.5.3
func (entity *Account) Find(context DatabaseService) error
Find will search for account by `username` if no identifier is present or by ID if it is.
func (*Account) FindByExternalID ¶
func (entity *Account) FindByExternalID(context DatabaseService) error
FindByExternalID will search for account by `request id`
func (*Account) FormTypeIsKnown ¶ added in v1.0.14
FormTypeIsKnown returns wether the form type and version are known to eApp
func (*Account) Get ¶ added in v0.5.3
func (entity *Account) Get(context DatabaseService, account int) (int, error)
Get the Account entity.
func (*Account) Save ¶ added in v0.5.3
func (entity *Account) Save(context DatabaseService, account int) (int, error)
Save the Account entity.
type AdditionalComments ¶
type AdditionalComments struct { PayloadHasComments Payload `json:"HasComments" sql:"-"` PayloadComments Payload `json:"Comments" sql:"-"` HasComments *Branch `json:"-"` Comments *Textarea `json:"-"` }
AdditionalComments represents the payload for the additional comments at the end of the form.
func (*AdditionalComments) ClearNoBranches ¶
func (entity *AdditionalComments) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*AdditionalComments) Marshal ¶
func (entity *AdditionalComments) Marshal() Payload
Marshal to payload structure
func (*AdditionalComments) Unmarshal ¶
func (entity *AdditionalComments) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Application ¶ added in v0.5.3
type Application struct { AccountID int // contains filtered or unexported fields }
Application represents a single SF application
func BlankApplication ¶
func BlankApplication(accountID int, formType string, formVersion string) Application
BlankApplication returns a constructed Application
func (*Application) ClearNoBranches ¶
func (a *Application) ClearNoBranches() error
ClearNoBranches clears all the branches answered "No" that must be re answered after rejection
func (*Application) EqipRequest ¶
func (a *Application) EqipRequest(env Settings, xmlContent string) (*eqip.ImportRequest, error)
EqipRequest returns a new eqip.ImportRequest, configured with the WS_* environment variables.
func (Application) FormType ¶
func (a Application) FormType() string
FormType is the type of the form
func (Application) FormVersion ¶
func (a Application) FormVersion() string
FormVersion is the version of the form
func (*Application) Hash ¶
func (a *Application) Hash() (string, error)
Hash returns the SHA256 hash of the application state in hexadecimal
func (Application) MarshalJSON ¶
func (a Application) MarshalJSON() ([]byte, error)
MarshalJSON implements json.Marshaller to custom marshal our JSON.
func (Application) Section ¶
func (a Application) Section(identifier string) Section
Section returns a single section of the application, by identifier
func (*Application) SetSection ¶
func (a *Application) SetSection(section Section)
SetSection sets a section in the application
func (*Application) UnmarshalJSON ¶
func (a *Application) UnmarshalJSON(bytes []byte) error
UnmarshalJSON implements json.Unmarshaller
type ArchivalPdf ¶ added in v0.5.6
type ArchivalPdf struct { Name string // document type name shown to users (e.g, Certification, Medical Release, etc.) Section string // eApp sub-section where signature information is stored DocType string // document type derived from e-QIP (e.g., CER, MEL, etc.) }
An ArchivalPdf represents a PDF (Portable Document Format) file that needs to be retained and submitted to e-QIP.
type Attachment ¶ added in v0.5.3
type Attachment struct { ID int `json:"id"` AccountID int `json:"-"` Description string `json:"description"` Filename string `json:"filename"` Size int64 `json:"size"` DocType string `json:"docType"` Raw []byte `json:"-"` }
Attachment stores information in regards to a file associated with the application.
func (*Attachment) Marshal ¶ added in v0.5.3
func (entity *Attachment) Marshal() Payload
Marshal to payload structure
func (*Attachment) Unmarshal ¶ added in v0.5.3
func (entity *Attachment) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type BasicAuthMembership ¶ added in v0.5.3
type BasicAuthMembership struct { ID int AccountID int Account *Account PasswordHash string Created time.Time }
BasicAuthMembership stores basic authentication information for the account.
func (*BasicAuthMembership) Delete ¶ added in v0.5.3
func (entity *BasicAuthMembership) Delete(context DatabaseService, account int) (int, error)
Delete the basic membership.
func (*BasicAuthMembership) Find ¶ added in v0.5.3
func (entity *BasicAuthMembership) Find(context DatabaseService) error
Find the basic membership.
func (*BasicAuthMembership) Get ¶ added in v0.5.3
func (entity *BasicAuthMembership) Get(context DatabaseService, account int) (int, error)
Get the basic membership.
func (*BasicAuthMembership) GetID ¶ added in v0.5.3
func (entity *BasicAuthMembership) GetID() int
GetID returns the entity identifier.
func (*BasicAuthMembership) HashPassword ¶ added in v0.5.3
func (entity *BasicAuthMembership) HashPassword(password string) error
HashPassword converts a plaintext password and generates a hash and updates the `PasswordHash` value.
func (*BasicAuthMembership) PasswordMatch ¶ added in v0.5.3
func (entity *BasicAuthMembership) PasswordMatch(password string) bool
PasswordMatch determines if a plain text password matches its equivalent password hash.
func (*BasicAuthMembership) Save ¶ added in v0.5.3
func (entity *BasicAuthMembership) Save(context DatabaseService, account int) (int, error)
Save the basic membership.
func (*BasicAuthMembership) SetID ¶ added in v0.5.3
func (entity *BasicAuthMembership) SetID(id int)
SetID sets the entity identifier.
type Benefit ¶ added in v0.5.3
type Benefit struct { PayloadBegin Payload `json:"Began,omitempty" sql:"-"` PayloadEnd Payload `json:"End,omitempty" sql:"-"` PayloadFrequency Payload `json:"Frequency,omitempty" sql:"-"` PayloadOtherFrequency Payload `json:"OtherFrequency,omitempty" sql:"-"` PayloadOtherFrequencyTypeExplanation Payload `json:"OtherFrequencyTypeExplanation,omitempty" sql:"-"` PayloadReceived Payload `json:"Received,omitempty" sql:"-"` PayloadCountry Payload `json:"Country" sql:"-"` PayloadValue Payload `json:"Value" sql:"-"` PayloadValueEstimated Payload `json:"ValueEstimated" sql:"-"` PayloadReason Payload `json:"Reason" sql:"-"` PayloadObligated Payload `json:"Obligated" sql:"-"` PayloadObligatedExplanation Payload `json:"ObligatedExplanation" sql:"-"` Begin *DateControl `json:"-"` End *DateControl `json:"-"` Frequency *Radio `json:"-"` OtherFrequency *Textarea `json:"-"` OtherFrequencyTypeExplanation *Textarea `json:"-"` Received *DateControl `json:"-"` Country *Country `json:"-"` Value *Number `json:"-"` ValueEstimated *Checkbox `json:"-"` Reason *Textarea `json:"-"` Obligated *Branch `json:"-"` ObligatedExplanation *Textarea `json:"-"` }
Benefit payload type.
type Branch ¶ added in v0.5.3
Branch is a basic yes/no input.
type Checkbox ¶ added in v0.5.3
type Checkbox struct { ID int `json:"-"` Value string `json:"value"` Checked bool `json:"checked,omitempty"` }
Checkbox is a basic input.
type CheckboxGroup ¶ added in v0.5.3
CheckboxGroup is a basic input.
func (*CheckboxGroup) Marshal ¶ added in v0.5.3
func (entity *CheckboxGroup) Marshal() Payload
Marshal to payload structure
func (*CheckboxGroup) Unmarshal ¶ added in v0.5.3
func (entity *CheckboxGroup) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type CitizenshipMultiple ¶ added in v0.5.3
type CitizenshipMultiple struct { PayloadHasMultiple Payload `json:"HasMultiple" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasMultiple *Branch `json:"-"` List *Collection `json:"-"` }
CitizenshipMultiple represents the payload for the citizenship multiple section.
func (*CitizenshipMultiple) ClearNoBranches ¶
func (entity *CitizenshipMultiple) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*CitizenshipMultiple) Marshal ¶ added in v0.5.3
func (entity *CitizenshipMultiple) Marshal() Payload
Marshal to payload structure
func (*CitizenshipMultiple) Unmarshal ¶ added in v0.5.3
func (entity *CitizenshipMultiple) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type CitizenshipPassports ¶ added in v0.5.3
type CitizenshipPassports struct { PayloadPassports Payload `json:"Passports" sql:"-"` Passports *Collection `json:"-"` }
CitizenshipPassports represents the payload for the citizenship passports section.
func (*CitizenshipPassports) ClearNoBranches ¶
func (entity *CitizenshipPassports) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*CitizenshipPassports) Marshal ¶ added in v0.5.3
func (entity *CitizenshipPassports) Marshal() Payload
Marshal to payload structure
func (*CitizenshipPassports) Unmarshal ¶ added in v0.5.3
func (entity *CitizenshipPassports) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type CitizenshipStatus ¶ added in v0.5.3
type CitizenshipStatus struct { PayloadCitizenshipStatus Payload `json:"CitizenshipStatus" sql:"-"` PayloadAbroadDocumentation Payload `json:"AbroadDocumentation" sql:"-"` PayloadExplanation Payload `json:"Explanation" sql:"-"` PayloadDocumentNumber Payload `json:"DocumentNumber" sql:"-"` PayloadDocumentIssued Payload `json:"DocumentIssued" sql:"-"` PayloadDocumentName Payload `json:"DocumentName" sql:"-"` PayloadDocumentExpiration Payload `json:"DocumentExpiration" sql:"-"` PayloadDocumentType Payload `json:"DocumentType" sql:"-"` PayloadPlaceIssued Payload `json:"PlaceIssued" sql:"-"` PayloadCertificateNumber Payload `json:"CertificateNumber" sql:"-"` PayloadCertificateIssued Payload `json:"CertificateIssued" sql:"-"` PayloadCertificateName Payload `json:"CertificateName" sql:"-"` PayloadCertificateCourtName Payload `json:"CertificateCourtName" sql:"-"` PayloadCertificateCourtAddress Payload `json:"CertificateCourtAddress" sql:"-"` PayloadBornOnMilitaryInstallation Payload `json:"BornOnMilitaryInstallation" sql:"-"` PayloadMilitaryBase Payload `json:"MilitaryBase" sql:"-"` PayloadEntryDate Payload `json:"EntryDate" sql:"-"` PayloadEntryLocation Payload `json:"EntryLocation" sql:"-"` PayloadPriorCitizenship Payload `json:"PriorCitizenship" sql:"-"` PayloadHasAlienRegistration Payload `json:"HasAlienRegistration" sql:"-"` PayloadAlienRegistrationNumber Payload `json:"AlienRegistrationNumber" sql:"-"` PayloadAlienRegistrationExpiration Payload `json:"AlienRegistrationExpiration" sql:"-"` PayloadBasis Payload `json:"Basis" sql:"-"` PayloadPermanentResidentCardNumber Payload `json:"PermanentResidentCardNumber" sql:"-"` PayloadResidenceStatus Payload `json:"ResidenceStatus" sql:"-"` CitizenshipStatus *Radio `json:"-"` AbroadDocumentation *Radio `json:"-"` Explanation *Textarea `json:"-"` DocumentNumber *Text `json:"-"` DocumentIssued *DateControl `json:"-"` DocumentName *Name `json:"-"` DocumentExpiration *DateControl `json:"-"` DocumentType *Radio `json:"-"` PlaceIssued *Location `json:"-"` CertificateNumber *Text `json:"-"` CertificateIssued *DateControl `json:"-"` CertificateName *Name `json:"-"` CertificateCourtName *Text `json:"-"` CertificateCourtAddress *Location `json:"-"` BornOnMilitaryInstallation *Branch `json:"-"` MilitaryBase *Text `json:"-"` EntryDate *DateControl `json:"-"` EntryLocation *Location `json:"-"` PriorCitizenship *Country `json:"-"` HasAlienRegistration *Branch `json:"-"` AlienRegistrationNumber *Text `json:"-"` AlienRegistrationExpiration *DateControl `json:"-"` Basis *Radio `json:"-"` PermanentResidentCardNumber *Text `json:"-"` ResidenceStatus *Text `json:"-"` }
CitizenshipStatus represents the payload for the citizenship status section.
func (*CitizenshipStatus) ClearNoBranches ¶
func (entity *CitizenshipStatus) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*CitizenshipStatus) Marshal ¶ added in v0.5.3
func (entity *CitizenshipStatus) Marshal() Payload
Marshal to payload structure
func (*CitizenshipStatus) Unmarshal ¶ added in v0.5.3
func (entity *CitizenshipStatus) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type CivilUnion ¶ added in v0.5.3
type CivilUnion struct { PayloadAddress Payload `json:"Address" sql:"-"` PayloadAddressSeparated Payload `json:"AddressSeparated" sql:"-"` PayloadAddressSeparatedNotApplicable Payload `json:"AddressSeparatedNotApplicable" sql:"-"` PayloadAlternateAddress Payload `json:"AlternateAddress" sql:"-"` PayloadBirthPlace Payload `json:"BirthPlace" sql:"-"` PayloadBirthdate Payload `json:"Birthdate" sql:"-"` PayloadCitizenship Payload `json:"Citizenship" sql:"-"` PayloadDateSeparated Payload `json:"DateSeparated" sql:"-"` PayloadDivorced Payload `json:"Divorced" sql:"-"` PayloadEmail Payload `json:"Email" sql:"-"` PayloadEmailNotApplicable Payload `json:"EmailNotApplicable" sql:"-"` PayloadEnteredCivilUnion Payload `json:"EnteredCivilUnion" sql:"-"` PayloadForeignBornDocument Payload `json:"ForeignBornDocument" sql:"-"` PayloadLocation Payload `json:"Location" sql:"-"` PayloadName Payload `json:"Name" sql:"-"` PayloadOtherNames Payload `json:"OtherNames" sql:"-"` PayloadSSN Payload `json:"SSN" sql:"-"` PayloadSeparated Payload `json:"Separated" sql:"-"` PayloadTelephone Payload `json:"Telephone" sql:"-"` PayloadUseCurrentAddress Payload `json:"UseCurrentAddress" sql:"-"` Address *Location `json:"-"` AddressSeparated *Location `json:"-"` AddressSeparatedNotApplicable *NotApplicable `json:"-"` AlternateAddress *PhysicalAddress `json:"-"` BirthPlace *Location `json:"-"` Birthdate *DateControl `json:"-"` Citizenship *Country `json:"-"` DateSeparated *DateControl `json:"-"` Divorced *Branch `json:"-"` Email *Email `json:"-"` EmailNotApplicable *NotApplicable `json:"-"` EnteredCivilUnion *DateControl `json:"-"` ForeignBornDocument *ForeignBornDocument `json:"-"` Location *Location `json:"-"` Name *Name `json:"-"` OtherNames *Collection `json:"-"` SSN *SSN `json:"-" sql:"-"` Separated *Branch `json:"-"` Telephone *Telephone `json:"-"` UseCurrentAddress *NotApplicable `json:"-"` }
CivilUnion is an item of named payloads.
func (*CivilUnion) Marshal ¶ added in v0.5.3
func (entity *CivilUnion) Marshal() Payload
Marshal to payload structure
func (*CivilUnion) Unmarshal ¶ added in v0.5.3
func (entity *CivilUnion) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ClearanceLevel ¶ added in v0.5.3
type ClearanceLevel struct { PayloadLevel Payload `json:"Level" sql:"-"` PayloadExplanation Payload `json:"Explanation" sql:"-"` Level *Radio `json:"-"` Explanation *Textarea `json:"-"` }
ClearanceLevel is a basic input.
func (*ClearanceLevel) Marshal ¶ added in v0.5.3
func (entity *ClearanceLevel) Marshal() Payload
Marshal to payload structure
func (*ClearanceLevel) Unmarshal ¶ added in v0.5.3
func (entity *ClearanceLevel) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type CoOwners ¶ added in v0.5.3
type CoOwners struct { PayloadList Payload `json:"List" sql:"-"` List *Collection `json:"-"` }
CoOwners payload.
type Collection ¶ added in v0.5.3
type Collection struct { PayloadBranch Payload `json:"branch" sql:"-"` Branch *Branch `json:"-" sql:"-"` Items []*CollectionItem `json:"items" sql:"-"` }
Collection represents a structure composed of zero or more items.
func (*Collection) ClearBranchItemsNo ¶
func (entity *Collection) ClearBranchItemsNo(firstKey string, additionalKeys ...string) error
ClearBranchItemsNo goes through every item in the collection, pulls out all the branches with the given name and clears the no
func (*Collection) ClearBranchNo ¶
func (entity *Collection) ClearBranchNo()
ClearBranchNo clears the no of the list's branch This is a convience wrapper that checks nil first.
func (*Collection) ClearNestedHasNo ¶
func (entity *Collection) ClearNestedHasNo(itemName string) error
ClearNestedHasNo goes through all the items in the collection, pulls out the named nested collection and clears its Has' No
func (*Collection) Marshal ¶ added in v0.5.3
func (entity *Collection) Marshal() Payload
Marshal to payload structure
func (*Collection) Unmarshal ¶ added in v0.5.3
func (entity *Collection) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type CollectionItem ¶ added in v0.5.3
type CollectionItem struct { Item map[string]json.RawMessage `json:"Item" sql:"-"` ID int `json:"-" sql:",pk"` Index int `json:"-" sql:",pk"` Name string `json:"-" sql:",pk"` Type string `json:"-"` ItemID int `json:"-"` }
CollectionItem is an item of named payloads directly used in a `Collection`.
func (CollectionItem) Each ¶ added in v0.5.3
Each loops through each entity in the collection item performing a given action
func (CollectionItem) GetItemValue ¶
func (ci CollectionItem) GetItemValue(key string) (Entity, error)
GetItemValue returns the entity stored at the key in the collection item
func (CollectionItem) MarshalJSON ¶
func (ci CollectionItem) MarshalJSON() ([]byte, error)
MarshalJSON implements json.Marshaller This implementation of MarshalJSON ensures that the values in Item have actually been turned into their Go representation at some point instead of just storing whatever is sent in /save This fixes a bug introduced by simplestorage where json objets with no correspondence to their go represenations would end up stored in collections and break XML generation
func (*CollectionItem) SetItemValue ¶
func (ci *CollectionItem) SetItemValue(key string, value Entity) error
SetItemValue sets a value for a key in the CollectionItem
func (*CollectionItem) UnmarshalJSON ¶
func (ci *CollectionItem) UnmarshalJSON(bytes []byte) error
UnmarshalJSON implements json.Unmarshaller
type Contacts ¶ added in v0.5.3
type Contacts struct { PayloadList Payload `json:"List" sql:"-"` List *Collection `json:"-"` }
Contacts payload.
type Country ¶ added in v0.5.3
type Country struct { ID int `json:"-"` Value []string `json:"value" pg:",array"` Comments string `json:"comments,omitempty"` }
Country is a basic input.
type DatabaseErrorNotFound ¶ added in v1.0.14
type DatabaseErrorNotFound string
DatabaseErrorNotFound is an error that indicates that the function failed because the seach returned zero results. It is expected to be returned by Select et al.
func (DatabaseErrorNotFound) Error ¶ added in v1.0.14
func (d DatabaseErrorNotFound) Error() string
type DatabaseService ¶ added in v0.5.3
type DatabaseService interface { Raw(query interface{}, params ...interface{}) error Find(query interface{}, callback func(query interface{})) FindAll(model interface{}) error Where(model interface{}, condition string, params ...interface{}) error ColumnsWhere(model interface{}, columns []string, condition string, params ...interface{}) error Insert(query ...interface{}) error Update(query interface{}) error Save(query ...interface{}) error Delete(query interface{}) error Select(query interface{}) error Count(model interface{}, condition string, params ...interface{}) int CountExpr(model interface{}, expr string, retval interface{}, condition string, params ...interface{}) Array(model interface{}, expr string, retval interface{}, condition string, params ...interface{}) Close() error }
DatabaseService represents a persisted data storage.
type DateControl ¶ added in v0.5.3
type DateControl struct { ID int `json:"-"` Month string `json:"month"` Day string `json:"day"` Year string `json:"year"` Estimated bool `json:"estimated"` }
DateControl is a basic input.
func (*DateControl) Date ¶ added in v0.5.3
func (entity *DateControl) Date() time.Time
Date is composed from the structure properties
func (*DateControl) Marshal ¶ added in v0.5.3
func (entity *DateControl) Marshal() Payload
Marshal to payload structure
func (*DateControl) Unmarshal ¶ added in v0.5.3
func (entity *DateControl) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type DateRange ¶ added in v0.5.3
type DateRange struct { PayloadFrom Payload `json:"from" sql:"-"` PayloadTo Payload `json:"to" sql:"-"` Present bool `json:"present"` From *DateControl `json:"-"` To *DateControl `json:"-"` }
DateRange is a basic input.
type Email ¶ added in v0.5.3
Email is a basic input.
type EmploymentActivity ¶ added in v0.5.3
type EmploymentActivity struct { ID int `json:"-"` Value string `json:"value"` OtherExplanation string `json:"otherExplanation,omitempty"` }
EmploymentActivity is a basic input.
func (*EmploymentActivity) Marshal ¶ added in v0.5.3
func (entity *EmploymentActivity) Marshal() Payload
Marshal to payload structure
func (*EmploymentActivity) Unmarshal ¶ added in v0.5.3
func (entity *EmploymentActivity) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Entity ¶ added in v0.5.3
type Entity interface { Marshaller }
Entity is a structure which can marshall and validate.
type ErrFieldInvalid ¶ added in v0.5.3
type ErrFieldInvalid struct {
Message string
}
ErrFieldInvalid represents an error for a field with an invalid value.
func (ErrFieldInvalid) Error ¶ added in v0.5.3
func (e ErrFieldInvalid) Error() string
Error returns the string representation of a Field Invalid error.
func (ErrFieldInvalid) Result ¶ added in v0.5.3
func (e ErrFieldInvalid) Result(fieldname string) interface{}
Result creates a struct that is properly formatted for the client-side validation.
type ErrFieldRequired ¶ added in v0.5.3
type ErrFieldRequired struct {
Message string
}
ErrFieldRequired represents an error for a field that requires data.
func (ErrFieldRequired) Error ¶ added in v0.5.3
func (e ErrFieldRequired) Error() string
Error is a basic representation of a Require Field error.
func (ErrFieldRequired) Result ¶ added in v0.5.3
func (e ErrFieldRequired) Result(fieldname string) interface{}
Result creates a struct that is properly formatted for the client-side validation.
type ErrInvalidLocation ¶ added in v0.5.3
type ErrInvalidLocation struct { Message string Suggestions []GeocodeResult }
ErrInvalidLocation represents an error for location information with additional options.
func (ErrInvalidLocation) Error ¶ added in v0.5.3
func (e ErrInvalidLocation) Error() string
Error returns the error message.
func (ErrInvalidLocation) Result ¶ added in v0.5.3
func (e ErrInvalidLocation) Result(fieldname string) interface{}
Result creates a struct that is properly formatted for the client-side validation.
type ErrorStack ¶ added in v0.5.3
type ErrorStack []ErrorStackResults
ErrorStack contains a list of ErrorStackResults that have been captured.
func NewErrorStack ¶ added in v0.5.3
func NewErrorStack(fieldname string, err error) ErrorStack
NewErrorStack creates a new stack of errors for a particular field.
func (*ErrorStack) Append ¶ added in v0.5.3
func (stack *ErrorStack) Append(fieldname string, err error)
Append adds an error to the list of errors. For those that implement the ValidationResult interface, the return value for Result(fieldname) will be used to populate the stack. This is to properly format error/validation information that is to be returned to the client-side.
func (ErrorStack) Error ¶ added in v0.5.3
func (stack ErrorStack) Error() string
Error is string representation of an ErrorStack and displays the total number of errors. This is to implement the error type.
func (ErrorStack) HasErrors ¶ added in v0.5.3
func (stack ErrorStack) HasErrors() bool
HasErrors checks if any errors exist
func (ErrorStack) Result ¶ added in v0.5.3
func (stack ErrorStack) Result(fieldname string) interface{}
Result creates a struct that is properly formatted for the client-validation.
type ErrorStackResults ¶ added in v0.5.3
type ErrorStackResults interface{}
ErrorStackResults is an interface to be used to represent a collection of interfaces. This currently has no additional methods
type FinancialBankruptcy ¶ added in v0.5.3
type FinancialBankruptcy struct { PayloadHasBankruptcy Payload `json:"HasBankruptcy" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasBankruptcy *Branch `json:"-"` List *Collection `json:"-"` }
FinancialBankruptcy represents the payload for the financial bankruptcy section.
func (*FinancialBankruptcy) ClearNoBranches ¶
func (entity *FinancialBankruptcy) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*FinancialBankruptcy) Marshal ¶ added in v0.5.3
func (entity *FinancialBankruptcy) Marshal() Payload
Marshal to payload structure
func (*FinancialBankruptcy) Unmarshal ¶ added in v0.5.3
func (entity *FinancialBankruptcy) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type FinancialCard ¶ added in v0.5.3
type FinancialCard struct { PayloadHasCardAbuse Payload `json:"HasCardAbuse" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasCardAbuse *Branch `json:"-"` List *Collection `json:"-"` }
FinancialCard represents the payload for the financial card section.
func (*FinancialCard) ClearNoBranches ¶
func (entity *FinancialCard) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*FinancialCard) Marshal ¶ added in v0.5.3
func (entity *FinancialCard) Marshal() Payload
Marshal to payload structure
func (*FinancialCard) Unmarshal ¶ added in v0.5.3
func (entity *FinancialCard) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type FinancialCredit ¶ added in v0.5.3
type FinancialCredit struct { PayloadHasCreditCounseling Payload `json:"HasCreditCounseling" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasCreditCounseling *Branch `json:"-"` List *Collection `json:"-"` }
FinancialCredit represents the payload for the financial credit section.
func (*FinancialCredit) ClearNoBranches ¶
func (entity *FinancialCredit) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*FinancialCredit) Marshal ¶ added in v0.5.3
func (entity *FinancialCredit) Marshal() Payload
Marshal to payload structure
func (*FinancialCredit) Unmarshal ¶ added in v0.5.3
func (entity *FinancialCredit) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type FinancialDelinquent ¶ added in v0.5.3
type FinancialDelinquent struct { PayloadHasDelinquent Payload `json:"HasDelinquent" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasDelinquent *Branch `json:"-"` List *Collection `json:"-"` }
FinancialDelinquent represents the payload for the financial delinquent section.
func (*FinancialDelinquent) ClearNoBranches ¶
func (entity *FinancialDelinquent) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*FinancialDelinquent) Marshal ¶ added in v0.5.3
func (entity *FinancialDelinquent) Marshal() Payload
Marshal to payload structure
func (*FinancialDelinquent) Unmarshal ¶ added in v0.5.3
func (entity *FinancialDelinquent) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type FinancialGambling ¶ added in v0.5.3
type FinancialGambling struct { PayloadHasGamblingDebt Payload `json:"HasGamblingDebt" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasGamblingDebt *Branch `json:"-"` List *Collection `json:"-"` }
FinancialGambling represents the payload for the financial gambling section.
func (*FinancialGambling) ClearNoBranches ¶
func (entity *FinancialGambling) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*FinancialGambling) Marshal ¶ added in v0.5.3
func (entity *FinancialGambling) Marshal() Payload
Marshal to payload structure
func (*FinancialGambling) Unmarshal ¶ added in v0.5.3
func (entity *FinancialGambling) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type FinancialNonpayment ¶ added in v0.5.3
type FinancialNonpayment struct { PayloadHasNonpayment Payload `json:"HasNonpayment" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasNonpayment *Branch `json:"-"` List *Collection `json:"-"` }
FinancialNonpayment represents the payload for the financial nonpayment section.
func (*FinancialNonpayment) ClearNoBranches ¶
func (entity *FinancialNonpayment) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*FinancialNonpayment) Marshal ¶ added in v0.5.3
func (entity *FinancialNonpayment) Marshal() Payload
Marshal to payload structure
func (*FinancialNonpayment) Unmarshal ¶ added in v0.5.3
func (entity *FinancialNonpayment) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type FinancialTaxes ¶ added in v0.5.3
type FinancialTaxes struct { PayloadHasTaxes Payload `json:"HasTaxes" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasTaxes *Branch `json:"-"` List *Collection `json:"-"` }
FinancialTaxes represents the payload for the financial taxes section.
func (*FinancialTaxes) ClearNoBranches ¶
func (entity *FinancialTaxes) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*FinancialTaxes) Marshal ¶ added in v0.5.3
func (entity *FinancialTaxes) Marshal() Payload
Marshal to payload structure
func (*FinancialTaxes) Unmarshal ¶ added in v0.5.3
func (entity *FinancialTaxes) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignActivitiesBenefits ¶ added in v0.5.3
type ForeignActivitiesBenefits struct { PayloadHasBenefits Payload `json:"HasBenefits" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasBenefits *Branch `json:"-"` List *Collection `json:"-"` }
ForeignActivitiesBenefits represents the payload for the foreign activities benefits section.
func (*ForeignActivitiesBenefits) ClearNoBranches ¶
func (entity *ForeignActivitiesBenefits) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignActivitiesBenefits) Marshal ¶ added in v0.5.3
func (entity *ForeignActivitiesBenefits) Marshal() Payload
Marshal to payload structure
func (*ForeignActivitiesBenefits) Unmarshal ¶ added in v0.5.3
func (entity *ForeignActivitiesBenefits) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignActivitiesDirect ¶ added in v0.5.3
type ForeignActivitiesDirect struct { PayloadHasInterests Payload `json:"HasInterests" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasInterests *Branch `json:"-"` List *Collection `json:"-"` }
ForeignActivitiesDirect represents the payload for the foreign activities direct section.
func (*ForeignActivitiesDirect) ClearNoBranches ¶
func (entity *ForeignActivitiesDirect) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignActivitiesDirect) Marshal ¶ added in v0.5.3
func (entity *ForeignActivitiesDirect) Marshal() Payload
Marshal to payload structure
func (*ForeignActivitiesDirect) Unmarshal ¶ added in v0.5.3
func (entity *ForeignActivitiesDirect) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignActivitiesIndirect ¶ added in v0.5.3
type ForeignActivitiesIndirect struct { PayloadHasInterests Payload `json:"HasInterests" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasInterests *Branch `json:"-"` List *Collection `json:"-"` }
ForeignActivitiesIndirect represents the payload for the foreign activities indirect section.
func (*ForeignActivitiesIndirect) ClearNoBranches ¶
func (entity *ForeignActivitiesIndirect) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignActivitiesIndirect) Marshal ¶ added in v0.5.3
func (entity *ForeignActivitiesIndirect) Marshal() Payload
Marshal to payload structure
func (*ForeignActivitiesIndirect) Unmarshal ¶ added in v0.5.3
func (entity *ForeignActivitiesIndirect) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignActivitiesRealEstate ¶ added in v0.5.3
type ForeignActivitiesRealEstate struct { PayloadHasInterests Payload `json:"HasInterests" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasInterests *Branch `json:"-"` List *Collection `json:"-"` }
ForeignActivitiesRealEstate represents the payload for the foreign activities real estate section.
func (*ForeignActivitiesRealEstate) ClearNoBranches ¶
func (entity *ForeignActivitiesRealEstate) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignActivitiesRealEstate) Marshal ¶ added in v0.5.3
func (entity *ForeignActivitiesRealEstate) Marshal() Payload
Marshal to payload structure
func (*ForeignActivitiesRealEstate) Unmarshal ¶ added in v0.5.3
func (entity *ForeignActivitiesRealEstate) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignActivitiesSupport ¶ added in v0.5.3
type ForeignActivitiesSupport struct { PayloadHasForeignSupport Payload `json:"HasForeignSupport" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignSupport *Branch `json:"-"` List *Collection `json:"-"` }
ForeignActivitiesSupport represents the payload for the foreign activities support section.
func (*ForeignActivitiesSupport) ClearNoBranches ¶
func (entity *ForeignActivitiesSupport) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignActivitiesSupport) Marshal ¶ added in v0.5.3
func (entity *ForeignActivitiesSupport) Marshal() Payload
Marshal to payload structure
func (*ForeignActivitiesSupport) Unmarshal ¶ added in v0.5.3
func (entity *ForeignActivitiesSupport) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBornDocument ¶ added in v0.5.3
type ForeignBornDocument struct { PayloadDocumentType Payload `json:"DocumentType" sql:"-"` PayloadOtherExplanation Payload `json:"OtherExplanation" sql:"-"` PayloadDocumentNumber Payload `json:"DocumentNumber" sql:"-"` PayloadDocumentExpiration Payload `json:"DocumentExpiration" sql:"-"` PayloadDocumentExpirationNotApplicable Payload `json:"DocumentExpirationNotApplicable" sql:"-"` DocumentType *Radio `json:"-"` OtherExplanation *Textarea `json:"-"` DocumentNumber *Text `json:"-"` DocumentExpiration *DateControl `json:"-"` DocumentExpirationNotApplicable *NotApplicable `json:"-"` }
ForeignBornDocument is a basic input.
func (*ForeignBornDocument) Marshal ¶ added in v0.5.3
func (entity *ForeignBornDocument) Marshal() Payload
Marshal to payload structure
func (*ForeignBornDocument) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBornDocument) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessAdvice ¶ added in v0.5.3
type ForeignBusinessAdvice struct { PayloadHasForeignAdvice Payload `json:"HasForeignAdvice" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignAdvice *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessAdvice represents the payload for the foreign business advice section.
func (*ForeignBusinessAdvice) ClearNoBranches ¶
func (entity *ForeignBusinessAdvice) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessAdvice) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessAdvice) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessAdvice) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessAdvice) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessConferences ¶ added in v0.5.3
type ForeignBusinessConferences struct { PayloadHasForeignConferences Payload `json:"HasForeignConferences" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignConferences *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessConferences represents the payload for the foreign business conferences section.
func (*ForeignBusinessConferences) ClearNoBranches ¶
func (entity *ForeignBusinessConferences) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessConferences) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessConferences) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessConferences) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessConferences) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessContact ¶ added in v0.5.3
type ForeignBusinessContact struct { PayloadHasForeignContact Payload `json:"HasForeignContact" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignContact *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessContact represents the payload for the foreign business contact section.
func (*ForeignBusinessContact) ClearNoBranches ¶
func (entity *ForeignBusinessContact) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessContact) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessContact) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessContact) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessContact) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessEmployment ¶ added in v0.5.3
type ForeignBusinessEmployment struct { PayloadHasForeignEmployment Payload `json:"HasForeignEmployment" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignEmployment *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessEmployment represents the payload for the foreign business employment section.
func (*ForeignBusinessEmployment) ClearNoBranches ¶
func (entity *ForeignBusinessEmployment) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessEmployment) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessEmployment) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessEmployment) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessEmployment) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessFamily ¶ added in v0.5.3
type ForeignBusinessFamily struct { PayloadHasForeignFamily Payload `json:"HasForeignFamily" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignFamily *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessFamily represents the payload for the foreign business family section.
func (*ForeignBusinessFamily) ClearNoBranches ¶
func (entity *ForeignBusinessFamily) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessFamily) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessFamily) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessFamily) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessFamily) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessPolitical ¶ added in v0.5.3
type ForeignBusinessPolitical struct { PayloadHasForeignPolitical Payload `json:"HasForeignPolitical" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignPolitical *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessPolitical represents the payload for the foreign business political section.
func (*ForeignBusinessPolitical) ClearNoBranches ¶
func (entity *ForeignBusinessPolitical) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessPolitical) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessPolitical) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessPolitical) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessPolitical) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessSponsorship ¶ added in v0.5.3
type ForeignBusinessSponsorship struct { PayloadHasForeignSponsorship Payload `json:"HasForeignSponsorship" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignSponsorship *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessSponsorship represents the payload for the foreign business sponsorship section.
func (*ForeignBusinessSponsorship) ClearNoBranches ¶
func (entity *ForeignBusinessSponsorship) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessSponsorship) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessSponsorship) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessSponsorship) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessSponsorship) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessVentures ¶ added in v0.5.3
type ForeignBusinessVentures struct { PayloadHasForeignVentures Payload `json:"HasForeignVentures" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignVentures *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessVentures represents the payload for the foreign business ventures section.
func (*ForeignBusinessVentures) ClearNoBranches ¶
func (entity *ForeignBusinessVentures) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessVentures) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessVentures) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessVentures) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessVentures) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignBusinessVoting ¶ added in v0.5.3
type ForeignBusinessVoting struct { PayloadHasForeignVoting Payload `json:"HasForeignVoting" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignVoting *Branch `json:"-"` List *Collection `json:"-"` }
ForeignBusinessVoting represents the payload for the foreign business voting section.
func (*ForeignBusinessVoting) ClearNoBranches ¶
func (entity *ForeignBusinessVoting) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignBusinessVoting) Marshal ¶ added in v0.5.3
func (entity *ForeignBusinessVoting) Marshal() Payload
Marshal to payload structure
func (*ForeignBusinessVoting) Unmarshal ¶ added in v0.5.3
func (entity *ForeignBusinessVoting) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignContacts ¶ added in v0.5.3
type ForeignContacts struct { PayloadHasForeignContacts Payload `json:"HasForeignContacts" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignContacts *Branch `json:"-"` List *Collection `json:"-"` }
ForeignContacts represents the payload for the foreign contacts section.
func (*ForeignContacts) ClearNoBranches ¶
func (entity *ForeignContacts) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignContacts) Marshal ¶ added in v0.5.3
func (entity *ForeignContacts) Marshal() Payload
Marshal to payload structure
func (*ForeignContacts) Unmarshal ¶ added in v0.5.3
func (entity *ForeignContacts) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignPassport ¶ added in v0.5.3
type ForeignPassport struct { PayloadHasPassports Payload `json:"HasPassports" sql:"-"` PayloadName Payload `json:"Name" sql:"-"` PayloadCard Payload `json:"Card" sql:"-"` PayloadNumber Payload `json:"Number" sql:"-"` PayloadIssued Payload `json:"Issued" sql:"-"` PayloadExpiration Payload `json:"Expiration" sql:"-"` PayloadComments Payload `json:"Comments" sql:"-"` HasPassports *Branch `json:"-"` Name *Name `json:"-"` Card *Radio `json:"-"` Number *Text `json:"-"` Issued *DateControl `json:"-"` Expiration *DateControl `json:"-"` Comments *Textarea `json:"-"` }
ForeignPassport represents the payload for the foreign passport section.
func (*ForeignPassport) ClearNoBranches ¶
func (entity *ForeignPassport) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignPassport) Marshal ¶ added in v0.5.3
func (entity *ForeignPassport) Marshal() Payload
Marshal to payload structure
func (*ForeignPassport) Unmarshal ¶ added in v0.5.3
func (entity *ForeignPassport) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type ForeignTravel ¶ added in v0.5.3
type ForeignTravel struct { PayloadHasForeignTravelOutside Payload `json:"HasForeignTravelOutside" sql:"-"` PayloadHasForeignTravelOfficial Payload `json:"HasForeignTravelOfficial" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasForeignTravelOutside *Branch `json:"-"` HasForeignTravelOfficial *Branch `json:"-"` List *Collection `json:"-"` }
ForeignTravel represents the payload for the foreign travel section.
func (*ForeignTravel) ClearNoBranches ¶
func (entity *ForeignTravel) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*ForeignTravel) Marshal ¶ added in v0.5.3
func (entity *ForeignTravel) Marshal() Payload
Marshal to payload structure
func (*ForeignTravel) Unmarshal ¶ added in v0.5.3
func (entity *ForeignTravel) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type GeocodeResult ¶ added in v0.5.3
type GeocodeResult struct { Street string Street2 string City string State string County string Country string Zipcode string Formatted string Partial bool Error string }
GeocodeResult represents geocoded information that has been transformed from the original source. All Geocoders should convert their location information into a GeocodeResult struct.
func (GeocodeResult) String ¶ added in v0.5.3
func (r GeocodeResult) String() string
String returns a friendly representation of a GeocodeResult.
type GeocodeResults ¶ added in v0.5.3
type GeocodeResults []GeocodeResult
GeocodeResults contains a list of found Result. It contains helper methods to determine if partial matches were found.
func (GeocodeResults) Empty ¶ added in v0.5.3
func (r GeocodeResults) Empty() bool
Empty determines if any results are available.
func (GeocodeResults) HasErrors ¶ added in v0.5.3
func (r GeocodeResults) HasErrors() bool
HasErrors checks if any of the results contains error information.
func (GeocodeResults) HasPartial ¶ added in v0.5.3
func (r GeocodeResults) HasPartial() bool
HasPartial determines if any of the matches is partial.
type GeocodeValues ¶ added in v0.5.3
type GeocodeValues struct { Street string Street2 string City string State string Zipcode string County string Country string }
GeocodeValues stores generic geospatial related query parameters.
type Geocoder ¶ added in v0.5.3
type Geocoder interface {
Validate(GeocodeValues) (GeocodeResults, error)
}
Geocoder is an interface for geocoding implementations.
var ( // Geocode is the geocoder to be used by the application. It points to an interface so that the // underlying implementation can be easily swapped out. Geocode Geocoder // ErrNoResultsFound is a generic error when results are not found but a request was valid. ErrNoResultsFound = errors.New("No geolocation results were found") )
type Height ¶ added in v0.5.3
Height is a basic input.
type HistoryEducation ¶ added in v0.5.3
type HistoryEducation struct { PayloadHasAttended Payload `json:"HasAttended" sql:"-"` PayloadHasDegree10 Payload `json:"HasDegree10" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasAttended *Branch `json:"-" sql:"-"` HasDegree10 *Branch `json:"-" sql:"-"` List *Collection `json:"-" sql:"-"` }
HistoryEducation represents the payload for the history education section.
func (*HistoryEducation) ClearNoBranches ¶
func (entity *HistoryEducation) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*HistoryEducation) Marshal ¶ added in v0.5.3
func (entity *HistoryEducation) Marshal() Payload
Marshal to payload structure
func (*HistoryEducation) Unmarshal ¶ added in v0.5.3
func (entity *HistoryEducation) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type HistoryEmployment ¶ added in v0.5.3
type HistoryEmployment struct { PayloadList Payload `json:"List" sql:"-"` PayloadEmploymentRecord Payload `json:"EmploymentRecord" sql:"-"` List *Collection `json:"-"` EmploymentRecord *Branch `json:"-"` }
HistoryEmployment represents the payload for the history employment section.
func (*HistoryEmployment) ClearNoBranches ¶
func (entity *HistoryEmployment) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*HistoryEmployment) Marshal ¶ added in v0.5.3
func (entity *HistoryEmployment) Marshal() Payload
Marshal to payload structure
func (*HistoryEmployment) Unmarshal ¶ added in v0.5.3
func (entity *HistoryEmployment) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type HistoryFederal ¶ added in v0.5.3
type HistoryFederal struct { PayloadHasFederalService Payload `json:"HasFederalService" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasFederalService *Branch `json:"-"` List *Collection `json:"-"` }
HistoryFederal represents the payload for the history federal section.
func (*HistoryFederal) ClearNoBranches ¶
func (entity *HistoryFederal) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*HistoryFederal) Marshal ¶ added in v0.5.3
func (entity *HistoryFederal) Marshal() Payload
Marshal to payload structure
func (*HistoryFederal) Unmarshal ¶ added in v0.5.3
func (entity *HistoryFederal) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type HistoryResidence ¶ added in v0.5.3
type HistoryResidence struct { PayloadList Payload `json:"List" sql:"-"` List *Collection `json:"-"` }
HistoryResidence represents the payload for the history residence section.
func (*HistoryResidence) ClearNoBranches ¶
func (entity *HistoryResidence) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*HistoryResidence) Marshal ¶ added in v0.5.3
func (entity *HistoryResidence) Marshal() Payload
Marshal to payload structure
func (*HistoryResidence) Unmarshal ¶ added in v0.5.3
func (entity *HistoryResidence) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type IdentificationBirthDate ¶ added in v0.5.3
type IdentificationBirthDate struct { PayloadDate Payload `json:"Date" sql:"-"` PayloadConfirmed Payload `json:"Confirmed" sql:"-"` Date *DateControl `json:"-"` Confirmed *Checkbox `json:"-"` }
IdentificationBirthDate represents the payload for the identification birth date section.
func (*IdentificationBirthDate) Marshal ¶ added in v0.5.3
func (entity *IdentificationBirthDate) Marshal() Payload
Marshal to payload structure
func (*IdentificationBirthDate) Unmarshal ¶ added in v0.5.3
func (entity *IdentificationBirthDate) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type IdentificationBirthPlace ¶ added in v0.5.3
type IdentificationBirthPlace struct { Payload Payload `json:"Location" sql:"-"` Location *Location `json:"-"` }
IdentificationBirthPlace represents the payload for the identification birth place section.
func (*IdentificationBirthPlace) Marshal ¶ added in v0.5.3
func (entity *IdentificationBirthPlace) Marshal() Payload
Marshal to payload structure
func (*IdentificationBirthPlace) Unmarshal ¶ added in v0.5.3
func (entity *IdentificationBirthPlace) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type IdentificationContacts ¶ added in v0.5.3
type IdentificationContacts struct { PayloadHomeEmail Payload `json:"HomeEmail" sql:"-"` PayloadWorkEmail Payload `json:"WorkEmail" sql:"-"` PayloadPhoneNumbers Payload `json:"PhoneNumbers" sql:"-"` HomeEmail *Email `json:"-"` WorkEmail *Email `json:"-"` PhoneNumbers *Collection `json:"-"` }
IdentificationContacts represents the payload for the identification contact information section.
func (*IdentificationContacts) Marshal ¶ added in v0.5.3
func (entity *IdentificationContacts) Marshal() Payload
Marshal to payload structure
func (*IdentificationContacts) Unmarshal ¶ added in v0.5.3
func (entity *IdentificationContacts) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type IdentificationName ¶ added in v0.5.3
IdentificationName represents the payload for the identification name section.
func (*IdentificationName) Marshal ¶ added in v0.5.3
func (entity *IdentificationName) Marshal() Payload
Marshal to payload structure
func (*IdentificationName) Unmarshal ¶ added in v0.5.3
func (entity *IdentificationName) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type IdentificationOtherNames ¶ added in v0.5.3
type IdentificationOtherNames struct { PayloadHasOtherNames Payload `json:"HasOtherNames" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasOtherNames *Branch `json:"-"` List *Collection `json:"-"` }
IdentificationOtherNames represents the payload for the identification other names section.
func (*IdentificationOtherNames) ClearNoBranches ¶
func (entity *IdentificationOtherNames) ClearNoBranches() error
ClearNoBranches Implements the Rejector interface and clears any nos on applicaiton kickback
func (*IdentificationOtherNames) Marshal ¶ added in v0.5.3
func (entity *IdentificationOtherNames) Marshal() Payload
Marshal to payload structure
func (*IdentificationOtherNames) Unmarshal ¶ added in v0.5.3
func (entity *IdentificationOtherNames) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type IdentificationPhysical ¶ added in v0.5.3
type IdentificationPhysical struct { PayloadComments Payload `json:"Comments" sql:"-"` PayloadEyeColor Payload `json:"EyeColor" sql:"-"` PayloadHairColor Payload `json:"HairColor" sql:"-"` PayloadHeight Payload `json:"Height" sql:"-"` PayloadSex Payload `json:"Sex" sql:"-"` PayloadWeight Payload `json:"Weight" sql:"-"` Comments *Textarea `json:"-"` EyeColor *Text `json:"-"` HairColor *Text `json:"-"` Sex *Text `json:"-"` Height *Height `json:"-"` Weight *Number `json:"-"` }
IdentificationPhysical represents the payload for the identification physical traits section.
func (*IdentificationPhysical) Marshal ¶ added in v0.5.3
func (entity *IdentificationPhysical) Marshal() Payload
Marshal to payload structure
func (*IdentificationPhysical) Unmarshal ¶ added in v0.5.3
func (entity *IdentificationPhysical) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type IdentificationSSN ¶ added in v0.5.3
type IdentificationSSN struct { Payload Payload `json:"ssn" sql:"-"` Verified bool `json:"verified"` SSN *SSN `json:"-" sql:"-"` }
IdentificationSSN represents the payload for the identification SSN section.
func (*IdentificationSSN) Marshal ¶ added in v0.5.3
func (entity *IdentificationSSN) Marshal() Payload
Marshal to payload structure
func (*IdentificationSSN) Unmarshal ¶ added in v0.5.3
func (entity *IdentificationSSN) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalAssociationsActivitiesToOverthrow ¶ added in v0.5.3
type LegalAssociationsActivitiesToOverthrow struct { PayloadHasActivities Payload `json:"HasActivities" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasActivities *Branch `json:"-"` List *Collection `json:"-"` }
LegalAssociationsActivitiesToOverthrow represents the payload for the legal associations activities to overthrow section.
func (*LegalAssociationsActivitiesToOverthrow) ClearNoBranches ¶
func (entity *LegalAssociationsActivitiesToOverthrow) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalAssociationsActivitiesToOverthrow) Marshal ¶ added in v0.5.3
func (entity *LegalAssociationsActivitiesToOverthrow) Marshal() Payload
Marshal to payload structure
func (*LegalAssociationsActivitiesToOverthrow) Unmarshal ¶ added in v0.5.3
func (entity *LegalAssociationsActivitiesToOverthrow) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalAssociationsAdvocating ¶ added in v0.5.3
type LegalAssociationsAdvocating struct { PayloadHasAdvocated Payload `json:"HasAdvocated" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasAdvocated *Branch `json:"-"` List *Collection `json:"-"` }
LegalAssociationsAdvocating represents the payload for the legal associations advocating section.
func (*LegalAssociationsAdvocating) ClearNoBranches ¶
func (entity *LegalAssociationsAdvocating) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalAssociationsAdvocating) Marshal ¶ added in v0.5.3
func (entity *LegalAssociationsAdvocating) Marshal() Payload
Marshal to payload structure
func (*LegalAssociationsAdvocating) Unmarshal ¶ added in v0.5.3
func (entity *LegalAssociationsAdvocating) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalAssociationsEngagedInTerrorism ¶ added in v0.5.3
type LegalAssociationsEngagedInTerrorism struct { PayloadHasEngaged Payload `json:"HasEngaged" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasEngaged *Branch `json:"-"` List *Collection `json:"-"` }
LegalAssociationsEngagedInTerrorism represents the payload for the legal associations engaged in terrorism section.
func (*LegalAssociationsEngagedInTerrorism) ClearNoBranches ¶
func (entity *LegalAssociationsEngagedInTerrorism) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalAssociationsEngagedInTerrorism) Marshal ¶ added in v0.5.3
func (entity *LegalAssociationsEngagedInTerrorism) Marshal() Payload
Marshal to payload structure
func (*LegalAssociationsEngagedInTerrorism) Unmarshal ¶ added in v0.5.3
func (entity *LegalAssociationsEngagedInTerrorism) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalAssociationsMembershipOverthrow ¶ added in v0.5.3
type LegalAssociationsMembershipOverthrow struct { PayloadHasOverthrow Payload `json:"HasOverthrow" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasOverthrow *Branch `json:"-"` List *Collection `json:"-"` }
LegalAssociationsMembershipOverthrow represents the payload for the legal associations membership to overthrow government section.
func (*LegalAssociationsMembershipOverthrow) ClearNoBranches ¶
func (entity *LegalAssociationsMembershipOverthrow) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalAssociationsMembershipOverthrow) Marshal ¶ added in v0.5.3
func (entity *LegalAssociationsMembershipOverthrow) Marshal() Payload
Marshal to payload structure
func (*LegalAssociationsMembershipOverthrow) Unmarshal ¶ added in v0.5.3
func (entity *LegalAssociationsMembershipOverthrow) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalAssociationsMembershipViolence ¶ added in v0.5.3
type LegalAssociationsMembershipViolence struct { PayloadHasViolence Payload `json:"HasViolence" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasViolence *Branch `json:"-"` List *Collection `json:"-"` }
LegalAssociationsMembershipViolence represents the payload for the legal associations memberhisp advocating violence section.
func (*LegalAssociationsMembershipViolence) ClearNoBranches ¶
func (entity *LegalAssociationsMembershipViolence) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalAssociationsMembershipViolence) Marshal ¶ added in v0.5.3
func (entity *LegalAssociationsMembershipViolence) Marshal() Payload
Marshal to payload structure
func (*LegalAssociationsMembershipViolence) Unmarshal ¶ added in v0.5.3
func (entity *LegalAssociationsMembershipViolence) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalAssociationsTerrorismAssociation ¶ added in v0.5.3
type LegalAssociationsTerrorismAssociation struct { PayloadHasTerrorism Payload `json:"HasTerrorism" sql:"-"` PayloadExplanation Payload `json:"Explanation" sql:"-"` HasTerrorism *Branch `json:"-"` Explanation *Textarea `json:"-"` }
LegalAssociationsTerrorismAssociation represents the payload for the legal associations with terrorism section.
func (*LegalAssociationsTerrorismAssociation) ClearNoBranches ¶
func (entity *LegalAssociationsTerrorismAssociation) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalAssociationsTerrorismAssociation) Marshal ¶ added in v0.5.3
func (entity *LegalAssociationsTerrorismAssociation) Marshal() Payload
Marshal to payload structure
func (*LegalAssociationsTerrorismAssociation) Unmarshal ¶ added in v0.5.3
func (entity *LegalAssociationsTerrorismAssociation) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalAssociationsTerroristOrganization ¶ added in v0.5.3
type LegalAssociationsTerroristOrganization struct { PayloadHasTerrorist Payload `json:"HasTerrorist" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasTerrorist *Branch `json:"-"` List *Collection `json:"-"` }
LegalAssociationsTerroristOrganization represents the payload for the legal associations with terrorist organizations section.
func (*LegalAssociationsTerroristOrganization) ClearNoBranches ¶
func (entity *LegalAssociationsTerroristOrganization) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalAssociationsTerroristOrganization) Marshal ¶ added in v0.5.3
func (entity *LegalAssociationsTerroristOrganization) Marshal() Payload
Marshal to payload structure
func (*LegalAssociationsTerroristOrganization) Unmarshal ¶ added in v0.5.3
func (entity *LegalAssociationsTerroristOrganization) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalCourt ¶ added in v0.5.3
type LegalCourt struct { PayloadHasCourtActions Payload `json:"HasCourtActions" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasCourtActions *Branch `json:"-"` List *Collection `json:"-"` }
LegalCourt represents the payload for the legal noncriminal court section.
func (*LegalCourt) ClearNoBranches ¶
func (entity *LegalCourt) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalCourt) Marshal ¶ added in v0.5.3
func (entity *LegalCourt) Marshal() Payload
Marshal to payload structure
func (*LegalCourt) Unmarshal ¶ added in v0.5.3
func (entity *LegalCourt) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalInvestigationsDebarred ¶ added in v0.5.3
type LegalInvestigationsDebarred struct { PayloadHasDebarment Payload `json:"HasDebarment" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasDebarment *Branch `json:"-"` List *Collection `json:"-"` }
LegalInvestigationsDebarred represents the payload for the legal investigations debarred section.
func (*LegalInvestigationsDebarred) ClearNoBranches ¶
func (entity *LegalInvestigationsDebarred) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalInvestigationsDebarred) Marshal ¶ added in v0.5.3
func (entity *LegalInvestigationsDebarred) Marshal() Payload
Marshal to payload structure
func (*LegalInvestigationsDebarred) Unmarshal ¶ added in v0.5.3
func (entity *LegalInvestigationsDebarred) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalInvestigationsHistory ¶ added in v0.5.3
type LegalInvestigationsHistory struct { PayloadHasHistory Payload `json:"HasHistory" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasHistory *Branch `json:"-"` List *Collection `json:"-"` }
LegalInvestigationsHistory represents the payload for the legal investigations history section.
func (*LegalInvestigationsHistory) ClearNoBranches ¶
func (entity *LegalInvestigationsHistory) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalInvestigationsHistory) Marshal ¶ added in v0.5.3
func (entity *LegalInvestigationsHistory) Marshal() Payload
Marshal to payload structure
func (*LegalInvestigationsHistory) Unmarshal ¶ added in v0.5.3
func (entity *LegalInvestigationsHistory) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalInvestigationsRevoked ¶ added in v0.5.3
type LegalInvestigationsRevoked struct { PayloadHasRevocations Payload `json:"HasRevocations" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasRevocations *Branch `json:"-"` List *Collection `json:"-"` }
LegalInvestigationsRevoked represents the payload for the legal investigatinos revoked section.
func (*LegalInvestigationsRevoked) ClearNoBranches ¶
func (entity *LegalInvestigationsRevoked) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalInvestigationsRevoked) Marshal ¶ added in v0.5.3
func (entity *LegalInvestigationsRevoked) Marshal() Payload
Marshal to payload structure
func (*LegalInvestigationsRevoked) Unmarshal ¶ added in v0.5.3
func (entity *LegalInvestigationsRevoked) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalPoliceAdditionalOffenses ¶ added in v0.5.3
type LegalPoliceAdditionalOffenses struct { PayloadHasOtherOffenses Payload `json:"HasOtherOffenses" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasOtherOffenses *Branch `json:"-"` List *Collection `json:"-"` }
LegalPoliceAdditionalOffenses represents the payload for the legal police additional offenses section.
func (*LegalPoliceAdditionalOffenses) ClearNoBranches ¶
func (entity *LegalPoliceAdditionalOffenses) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalPoliceAdditionalOffenses) Marshal ¶ added in v0.5.3
func (entity *LegalPoliceAdditionalOffenses) Marshal() Payload
Marshal to payload structure
func (*LegalPoliceAdditionalOffenses) Unmarshal ¶ added in v0.5.3
func (entity *LegalPoliceAdditionalOffenses) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalPoliceDomesticViolence ¶ added in v0.5.3
type LegalPoliceDomesticViolence struct { PayloadHasDomesticViolence Payload `json:"HasDomesticViolence" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasDomesticViolence *Branch `json:"-"` List *Collection `json:"-"` }
LegalPoliceDomesticViolence represents the payload for the legal police domestic violence section.
func (*LegalPoliceDomesticViolence) ClearNoBranches ¶
func (entity *LegalPoliceDomesticViolence) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalPoliceDomesticViolence) Marshal ¶ added in v0.5.3
func (entity *LegalPoliceDomesticViolence) Marshal() Payload
Marshal to payload structure
func (*LegalPoliceDomesticViolence) Unmarshal ¶ added in v0.5.3
func (entity *LegalPoliceDomesticViolence) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalPoliceOffenses ¶ added in v0.5.3
type LegalPoliceOffenses struct { PayloadHasOffenses Payload `json:"HasOffenses" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasOffenses *Branch `json:"-"` List *Collection `json:"-"` }
LegalPoliceOffenses represents the payload for the legal police offenses section.
func (*LegalPoliceOffenses) ClearNoBranches ¶
func (entity *LegalPoliceOffenses) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalPoliceOffenses) Marshal ¶ added in v0.5.3
func (entity *LegalPoliceOffenses) Marshal() Payload
Marshal to payload structure
func (*LegalPoliceOffenses) Unmarshal ¶ added in v0.5.3
func (entity *LegalPoliceOffenses) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalTechnologyManipulating ¶ added in v0.5.3
type LegalTechnologyManipulating struct { PayloadHasManipulating Payload `json:"HasManipulating" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasManipulating *Branch `json:"-"` List *Collection `json:"-"` }
LegalTechnologyManipulating represents the payload for the legal technology manipulating section.
func (*LegalTechnologyManipulating) ClearNoBranches ¶
func (entity *LegalTechnologyManipulating) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalTechnologyManipulating) Marshal ¶ added in v0.5.3
func (entity *LegalTechnologyManipulating) Marshal() Payload
Marshal to payload structure
func (*LegalTechnologyManipulating) Unmarshal ¶ added in v0.5.3
func (entity *LegalTechnologyManipulating) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalTechnologyUnauthorized ¶ added in v0.5.3
type LegalTechnologyUnauthorized struct {}
LegalTechnologyUnauthorized represents the payload for the legal technology unauthorized access section.
func (*LegalTechnologyUnauthorized) ClearNoBranches ¶
func (entity *LegalTechnologyUnauthorized) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalTechnologyUnauthorized) Marshal ¶ added in v0.5.3
func (entity *LegalTechnologyUnauthorized) Marshal() Payload
Marshal to payload structure
func (*LegalTechnologyUnauthorized) Unmarshal ¶ added in v0.5.3
func (entity *LegalTechnologyUnauthorized) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type LegalTechnologyUnlawful ¶ added in v0.5.3
type LegalTechnologyUnlawful struct { PayloadHasUnlawful Payload `json:"HasUnlawful" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasUnlawful *Branch `json:"-"` List *Collection `json:"-"` }
LegalTechnologyUnlawful represents the payload for the legal technology unlawful use section.
func (*LegalTechnologyUnlawful) ClearNoBranches ¶
func (entity *LegalTechnologyUnlawful) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*LegalTechnologyUnlawful) Marshal ¶ added in v0.5.3
func (entity *LegalTechnologyUnlawful) Marshal() Payload
Marshal to payload structure
func (*LegalTechnologyUnlawful) Unmarshal ¶ added in v0.5.3
func (entity *LegalTechnologyUnlawful) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Location ¶ added in v0.5.3
type Location struct { ID int `json:"-"` Layout string `json:"layout,omitempty"` Street1 string `json:"street,omitempty"` Street2 string `json:"street2,omitempty"` City string `json:"city,omitempty"` State string `json:"state,omitempty"` Zipcode string `json:"zipcode,omitempty"` County string `json:"county,omitempty"` Country string `json:"country,omitempty"` CountryComments string `json:"countryComments,omitempty"` Validated bool `json:"validated,omitempty"` }
Location is a basic input.
func (*Location) IsDomestic ¶ added in v0.5.3
IsDomestic returns whether the location is in the United States.
func (*Location) IsInternational ¶ added in v0.5.3
IsInternational returns whether the location is outside the United States and not a postal address.
func (*Location) IsPostOffice ¶ added in v0.5.3
IsPostOffice returns whether the location is APO, FPO, or DPO.
type LogFields ¶ added in v0.5.3
type LogFields map[string]interface{}
LogFields are named keys to hold additional information to be reported in the log messages.
type LogService ¶ added in v0.5.3
type LogService interface { AddField(name string, value interface{}) Print(message string, fields LogFields) PrintError(message string, err error, fields LogFields) Debug(message string, fields LogFields) DebugError(message string, err error, fields LogFields) Warn(message string, fields LogFields) WarnError(message string, err error, fields LogFields) Info(message string, fields LogFields) InfoError(message string, err error, fields LogFields) Fatal(message string, fields LogFields) FatalError(message string, err error, fields LogFields) Panic(message string, fields LogFields) PanicError(message string, err error, fields LogFields) }
LogService represents common methods for a logging service.
type Marshaller ¶ added in v0.5.3
Marshaller is structure which can marshal and unmarshal JSON.
type Migration ¶ added in v0.5.3
type Migration struct {
Env Settings
}
Migration is a service used for data storage migrations.
type MilitaryDisciplinary ¶ added in v0.5.3
type MilitaryDisciplinary struct { PayloadHasDisciplinary Payload `json:"HasDisciplinary" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasDisciplinary *Branch `json:"-"` List *Collection `json:"-"` }
MilitaryDisciplinary represents the payload for the military disposition section.
func (*MilitaryDisciplinary) ClearNoBranches ¶
func (entity *MilitaryDisciplinary) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*MilitaryDisciplinary) Marshal ¶ added in v0.5.3
func (entity *MilitaryDisciplinary) Marshal() Payload
Marshal to payload structure
func (*MilitaryDisciplinary) Unmarshal ¶ added in v0.5.3
func (entity *MilitaryDisciplinary) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type MilitaryForeign ¶ added in v0.5.3
type MilitaryForeign struct { PayloadList Payload `json:"List" sql:"-"` List *Collection `json:"-"` }
MilitaryForeign represents the payload for the military foreign section.
func (*MilitaryForeign) ClearNoBranches ¶
func (entity *MilitaryForeign) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*MilitaryForeign) Marshal ¶ added in v0.5.3
func (entity *MilitaryForeign) Marshal() Payload
Marshal to payload structure
func (*MilitaryForeign) Unmarshal ¶ added in v0.5.3
func (entity *MilitaryForeign) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type MilitaryHistory ¶ added in v0.5.3
type MilitaryHistory struct { PayloadHasServed Payload `json:"HasServed" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasServed *Branch `json:"-"` List *Collection `json:"-"` }
MilitaryHistory represents the payload for the military history section.
func (*MilitaryHistory) ClearNoBranches ¶
func (entity *MilitaryHistory) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*MilitaryHistory) Marshal ¶ added in v0.5.3
func (entity *MilitaryHistory) Marshal() Payload
Marshal to payload structure
func (*MilitaryHistory) Unmarshal ¶ added in v0.5.3
func (entity *MilitaryHistory) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type MilitarySelective ¶ added in v0.5.3
type MilitarySelective struct { PayloadWasBornAfter Payload `json:"WasBornAfter" sql:"-"` PayloadHasRegistered Payload `json:"HasRegistered" sql:"-"` PayloadRegistrationNumber Payload `json:"RegistrationNumber" sql:"-"` PayloadExplanation Payload `json:"Explanation" sql:"-"` PayloadHasRegisteredNotApplicable Payload `json:"HasRegisteredNotApplicable" sql:"-"` WasBornAfter *Branch `json:"-"` HasRegistered *Branch `json:"-"` RegistrationNumber *Text `json:"-"` Explanation *Textarea `json:"-"` HasRegisteredNotApplicable *NotApplicable `json:"-"` }
MilitarySelective represents the payload for the military service section.
func (*MilitarySelective) ClearNoBranches ¶
func (entity *MilitarySelective) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*MilitarySelective) Marshal ¶ added in v0.5.3
func (entity *MilitarySelective) Marshal() Payload
Marshal to payload structure
func (*MilitarySelective) Unmarshal ¶ added in v0.5.3
func (entity *MilitarySelective) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Name ¶ added in v0.5.3
type Name struct { ID int `json:"-"` First string `json:"first"` FirstInitialOnly bool `json:"firstInitialOnly"` Middle string `json:"middle"` MiddleInitialOnly bool `json:"middleInitialOnly"` NoMiddleName bool `json:"noMiddleName"` Last string `json:"last"` Suffix string `json:"suffix"` SuffixOther string `json:"suffixOther"` }
Name is a basic input.
type NotApplicable ¶ added in v0.5.3
NotApplicable is a basic input.
func (*NotApplicable) Marshal ¶ added in v0.5.3
func (entity *NotApplicable) Marshal() Payload
Marshal to payload structure
func (*NotApplicable) Unmarshal ¶ added in v0.5.3
func (entity *NotApplicable) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Number ¶ added in v0.5.3
Number is a basic input.
type Payload ¶ added in v0.5.3
type Payload struct { Type string `json:"type"` Props json.RawMessage `json:"props,omitempty"` }
Payload is a basic structure to encapsulate a generic structure.
func MarshalPayloadEntity ¶ added in v0.5.3
MarshalPayloadEntity basic payload structure with an entity.
func (Payload) Entity ¶ added in v0.5.3
Entity returns the appropriate entity as an interface based on its type.
func (Payload) SafeEntity ¶ added in v0.5.3
SafeEntity returns the appropriate entity as an interface based on its type and is at the section level.
type PdfService ¶ added in v0.5.6
type PdfService interface {
GenerateReleases(account Account, app Application) ([]Attachment, error)
}
PdfService declares operations to create and query archival PDFs.
type PhysicalAddress ¶ added in v0.5.3
type PhysicalAddress struct { PayloadHasDifferentAddress Payload `json:"HasDifferentAddress" sql:"-"` PayloadAddress Payload `json:"Address" sql:"-"` PayloadTelephone Payload `json:"Telephone" sql:"-"` HasDifferentAddress *Branch `json:"-"` Address *Location `json:"-"` Telephone *Telephone `json:"-"` }
PhysicalAddress is a basic input.
func (*PhysicalAddress) Marshal ¶ added in v0.5.3
func (entity *PhysicalAddress) Marshal() Payload
Marshal to payload structure
func (*PhysicalAddress) Unmarshal ¶ added in v0.5.3
func (entity *PhysicalAddress) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type PsychologicalCompetence ¶ added in v0.5.3
type PsychologicalCompetence struct { PayloadIsIncompetent Payload `json:"IsIncompetent" sql:"-"` PayloadList Payload `json:"List" sql:"-"` IsIncompetent *Branch `json:"-"` List *Collection `json:"-"` }
PsychologicalCompetence represents the payload for the psychological competence section.
func (*PsychologicalCompetence) ClearNoBranches ¶
func (entity *PsychologicalCompetence) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*PsychologicalCompetence) Marshal ¶ added in v0.5.3
func (entity *PsychologicalCompetence) Marshal() Payload
Marshal to payload structure
func (*PsychologicalCompetence) Unmarshal ¶ added in v0.5.3
func (entity *PsychologicalCompetence) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type PsychologicalConsultations ¶ added in v0.5.3
type PsychologicalConsultations struct { PayloadConsulted Payload `json:"Consulted" sql:"-"` PayloadList Payload `json:"List" sql:"-"` Consulted *Branch `json:"-"` List *Collection `json:"-"` }
PsychologicalConsultations represents the payload for the psychological consultations section.
func (*PsychologicalConsultations) ClearNoBranches ¶
func (entity *PsychologicalConsultations) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*PsychologicalConsultations) Marshal ¶ added in v0.5.3
func (entity *PsychologicalConsultations) Marshal() Payload
Marshal to payload structure
func (*PsychologicalConsultations) Unmarshal ¶ added in v0.5.3
func (entity *PsychologicalConsultations) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type PsychologicalDiagnoses ¶ added in v0.5.3
type PsychologicalDiagnoses struct { PayloadDiagnosed Payload `json:"Diagnosed" sql:"-"` PayloadDidNotConsult Payload `json:"DidNotConsult" sql:"-"` PayloadDiagnosisList Payload `json:"DiagnosisList" sql:"-"` PayloadInTreatment Payload `json:"InTreatment" sql:"-"` PayloadTreatmentList Payload `json:"TreatmentList" sql:"-"` Diagnosed *Branch `json:"-"` DidNotConsult *Branch `json:"-"` DiagnosisList *Collection `json:"-"` InTreatment *Branch `json:"-"` TreatmentList *Collection `json:"-"` }
PsychologicalDiagnoses represents the payload for the psychological diagnosis section.
func (*PsychologicalDiagnoses) ClearNoBranches ¶
func (entity *PsychologicalDiagnoses) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*PsychologicalDiagnoses) Marshal ¶ added in v0.5.3
func (entity *PsychologicalDiagnoses) Marshal() Payload
Marshal to payload structure
func (*PsychologicalDiagnoses) Unmarshal ¶ added in v0.5.3
func (entity *PsychologicalDiagnoses) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type PsychologicalExisting ¶ added in v0.5.3
type PsychologicalExisting struct { PayloadHasCondition Payload `json:"HasCondition" sql:"-"` PayloadReceivedTreatment Payload `json:"ReceivedTreatment" sql:"-"` PayloadExplanation Payload `json:"Explanation" sql:"-"` PayloadTreatmentList Payload `json:"TreatmentList" sql:"-"` PayloadDidNotFollow Payload `json:"DidNotFollow" sql:"-"` PayloadDidNotFollowExplanation Payload `json:"DidNotFollowExplanation" sql:"-"` HasCondition *Branch `json:"-"` ReceivedTreatment *Radio `json:"-"` Explanation *Textarea `json:"-"` TreatmentList *Collection `json:"-"` DidNotFollow *Branch `json:"-"` DidNotFollowExplanation *Textarea `json:"-"` }
PsychologicalExisting represents the payload for the psychological existing conditions section.
func (*PsychologicalExisting) Marshal ¶ added in v0.5.3
func (entity *PsychologicalExisting) Marshal() Payload
Marshal to payload structure
func (*PsychologicalExisting) Unmarshal ¶ added in v0.5.3
func (entity *PsychologicalExisting) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type PsychologicalHospitalizations ¶ added in v0.5.3
type PsychologicalHospitalizations struct { PayloadHospitalized Payload `json:"Hospitalized" sql:"-"` PayloadList Payload `json:"List" sql:"-"` Hospitalized *Branch `json:"-"` List *Collection `json:"-"` }
PsychologicalHospitalizations represents the payload for the psychological hospitalizations section.
func (*PsychologicalHospitalizations) ClearNoBranches ¶
func (entity *PsychologicalHospitalizations) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*PsychologicalHospitalizations) Marshal ¶ added in v0.5.3
func (entity *PsychologicalHospitalizations) Marshal() Payload
Marshal to payload structure
func (*PsychologicalHospitalizations) Unmarshal ¶ added in v0.5.3
func (entity *PsychologicalHospitalizations) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Radio ¶ added in v0.5.3
type Radio struct { ID int `json:"-"` Value string `json:"value"` Checked bool `json:"checked,omitempty"` }
Radio is a basic input.
type ReasonLeft ¶ added in v0.5.3
type ReasonLeft struct { PayloadComments Payload `json:"Comments" sql:"-"` PayloadReasons Payload `json:"Reasons" sql:"-"` PayloadReasonDescription Payload `json:"ReasonDescription" sql:"-"` Comments *Textarea `json:"-"` Reasons *Collection `json:"-"` ReasonDescription *Textarea `json:"-"` }
ReasonLeft is a basic input.
func (*ReasonLeft) Marshal ¶ added in v0.5.3
func (entity *ReasonLeft) Marshal() Payload
Marshal to payload structure
func (*ReasonLeft) Unmarshal ¶ added in v0.5.3
func (entity *ReasonLeft) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Rejector ¶
type Rejector interface {
ClearNoBranches() error
}
Rejector interface allows an entity to have nos cleared when the application is kicked back
type RelationshipsCohabitants ¶ added in v0.5.3
type RelationshipsCohabitants struct { PayloadHasCohabitant Payload `json:"HasCohabitant" sql:"-"` PayloadCohabitantList Payload `json:"CohabitantList" sql:"-"` HasCohabitant *Branch `json:"-"` CohabitantList *Collection `json:"-"` }
RelationshipsCohabitants represents the payload for the relationships cohabitants section.
func (*RelationshipsCohabitants) ClearNoBranches ¶
func (entity *RelationshipsCohabitants) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*RelationshipsCohabitants) Marshal ¶ added in v0.5.3
func (entity *RelationshipsCohabitants) Marshal() Payload
Marshal to payload structure
func (*RelationshipsCohabitants) Unmarshal ¶ added in v0.5.3
func (entity *RelationshipsCohabitants) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type RelationshipsMarital ¶ added in v0.5.3
type RelationshipsMarital struct { PayloadStatus Payload `json:"Status" sql:"-"` PayloadCivilUnion Payload `json:"CivilUnion" sql:"-"` PayloadDivorcedList Payload `json:"DivorcedList" sql:"-"` Status *Radio `json:"-"` CivilUnion *CivilUnion `json:"-"` DivorcedList *Collection `json:"-"` }
RelationshipsMarital represents the payload for the relationships marital section.
func (*RelationshipsMarital) ClearNoBranches ¶
func (entity *RelationshipsMarital) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*RelationshipsMarital) Marshal ¶ added in v0.5.3
func (entity *RelationshipsMarital) Marshal() Payload
Marshal to payload structure
func (*RelationshipsMarital) Unmarshal ¶ added in v0.5.3
func (entity *RelationshipsMarital) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type RelationshipsPeople ¶ added in v0.5.3
type RelationshipsPeople struct { PayloadList Payload `json:"List" sql:"-"` List *Collection `json:"-"` }
RelationshipsPeople represents the payload for the relationships people section.
func (*RelationshipsPeople) ClearNoBranches ¶
func (entity *RelationshipsPeople) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*RelationshipsPeople) Marshal ¶ added in v0.5.3
func (entity *RelationshipsPeople) Marshal() Payload
Marshal to payload structure
func (*RelationshipsPeople) Unmarshal ¶ added in v0.5.3
func (entity *RelationshipsPeople) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type RelationshipsRelatives ¶ added in v0.5.3
type RelationshipsRelatives struct { PayloadList Payload `json:"List" sql:"-"` List *Collection `json:"-"` }
RelationshipsRelatives represents the payload for the relationships relatives section.
func (*RelationshipsRelatives) ClearNoBranches ¶
func (entity *RelationshipsRelatives) ClearNoBranches() error
ClearNoBranches clears any questions answered nos on a kickback
func (*RelationshipsRelatives) Marshal ¶ added in v0.5.3
func (entity *RelationshipsRelatives) Marshal() Payload
Marshal to payload structure
func (*RelationshipsRelatives) Unmarshal ¶ added in v0.5.3
func (entity *RelationshipsRelatives) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SAMLResponseType ¶ added in v1.0.6
type SAMLResponseType string
SAMLResponseType represents the type of a SAML response received from the identity server
const ( // AuthnSAMLResponseType represents an Aunthn Response AuthnSAMLResponseType SAMLResponseType = "AuthnSAMLResponseType" // LogoutSAMLResponseType represents a Logout Response LogoutSAMLResponseType SAMLResponseType = "LogoutSAMLResponseType" )
type SSN ¶ added in v0.5.3
type SSN struct { ID int `json:"-"` First string `json:"first"` Middle string `json:"middle"` Last string `json:"last"` NotApplicable bool `json:"notApplicable"` }
SSN is a basic input.
type SamlService ¶ added in v0.5.3
type SamlService interface { CreateAuthenticationRequest() (string, string, error) ValidateAuthenticationResponse(encoded string) (string, string, error) CreateSLORequest(string, string) (string, string, error) ResponseType(encoded string) (SAMLResponseType, error) }
SamlService represents a service to request and validate SAML responses.
type Section ¶
type Section interface { Entity }
Section interface represents a top level section in the form Right now that's just an entity, but it would be nice if we could separate Sections from things like text fields in the future.
type SectionInformation ¶ added in v0.5.6
type SectionInformation struct { Name string Subsection string Payload string // contains filtered or unexported fields }
SectionInformation represents a structure to quickly organize the different sections and subsections with the payload type(s).
func Catalogue ¶ added in v0.5.6
func Catalogue() []SectionInformation
Catalogue eturns an array of the sub-sections of the form
type Sentence ¶ added in v0.5.3
type Sentence struct { PayloadDescription Payload `json:"Description" sql:"-"` PayloadExceedsYear Payload `json:"ExceedsYear" sql:"-"` PayloadIncarcerated Payload `json:"Incarcerated" sql:"-"` PayloadIncarcerationDates Payload `json:"IncarcerationDates" sql:"-"` PayloadIncarcerationDatesNA Payload `json:"IncarcerationDatesNA" sql:"-"` PayloadProbationDates Payload `json:"ProbationDates" sql:"-"` PayloadProbationDatesNA Payload `json:"ProbationDatesNA" sql:"-"` Description *Textarea `json:"-" sql:"-"` ExceedsYear *Branch `json:"-" sql:"-"` Incarcerated *Branch `json:"-" sql:"-"` IncarcerationDates *DateRange `json:"-" sql:"-"` IncarcerationDatesNA *NotApplicable `json:"-" sql:"-"` ProbationDates *DateRange `json:"-" sql:"-"` ProbationDatesNA *NotApplicable `json:"-" sql:"-"` }
Sentence is a basic input.
type Serializer ¶
type Serializer interface { // SerializeApplication turns an Application into bytes SerializeApplication(Application) ([]byte, error) // DeserializeApplication turns bytes into an Application DeserializeApplication(accountID int, formType string, formVersion string, body []byte) (Application, error) // SerializeAttachment turns an attachment into two byte arrays for storage in the db // The first one is the meatadata, and the second one is the body SerializeAttachment(attachment Attachment) ([]byte, []byte, error) // DeserializeAttachment turns bytes into an Attachment DeserializeAttachment(accountID int, attachmentID int, metadata []byte, body []byte) (Attachment, error) }
Serializer is an interface that sits between the domain models and the database. It is able to serialize and deserialize Applications and Attachments
type Session ¶
type Session struct { AccountID int `db:"account_id"` SessionKey string `db:"session_key"` ExpirationDate time.Time `db:"expiration_date"` SessionIndex sql.NullString `db:"session_index"` // This is a value related to SAML SLO }
Session contains all the information about a given user session in eApp
type SessionService ¶
type SessionService interface { // UserDidAuthenticate creates a session for a newly logged in user UserDidAuthenticate(accountID int, sessionIndex sql.NullString) (sessionKey string, err error) // GetAccountIfSessionIsValid returns an account if the session is valid, or ErrValidSessionNotFound otherwise GetAccountIfSessionIsValid(sessionKey string) (account Account, session Session, err error) // UserDidLogout invalidates a session for a newly logged out user UserDidLogout(sessionKey string) error }
SessionService backs user authentication -- providing a way to verify & modify session status
type Settings ¶ added in v0.5.3
type Settings interface { Configure() Has(string) bool String(string) string True(string) bool Int(string) int }
Settings represents environments settings to pull configuration information. This may be via environment variables or a specific environment like CloudFoundry.
type Signature ¶ added in v0.5.3
type Signature struct { PayloadName Payload `json:"Name" sql:"-"` PayloadDate Payload `json:"Date" sql:"-"` Name *Text `json:"-" sql:"-"` Date *DateControl `json:"-" sql:"-"` }
Signature is a basic input.
type StorageService ¶
type StorageService interface { // CreateApplication creates an application in the db. Errors if already exists. CreateApplication(app Application) error // UpdateApplication replaces an existing application with the passed in one. UpdateApplication(app Application) error // SaveSection replaces a single section in the given application with the passed in section SaveSection(section Section, accountID int) error // LoadApplication returns the given application from the db. LoadApplication(accountID int) (Application, error) // DeleteApplication deletes all the form data for a given account DeleteApplication(accountID int) error // CreateAttachment creates an attachment in the database CreateAttachment(attachment *Attachment) error // LoadAttachment loads an attachment from the database LoadAttachment(accountID int, attachmentID int) (Attachment, error) // ListAttachmentMetadata returns a slice of attachments' metadata for a given account. ListAttachmentsMetadata(accountID int) ([]Attachment, error) // DeleteAttachment deletes an attachment for the given account DeleteAttachment(accountID int, attachmentID int) error // CreateSession creates a new session record in the db CreateSession(accountID int, sessionKey string, sessionIndex sql.NullString, expirationDuration time.Duration) error // FetchPossiblyExpiredSession returns a session row by account ID regardless of wether it is expired // This is potentially dangerous, it is only intended to be used during the new login flow, never to check // on a valid session for authentication purposes. FetchPossiblyExpiredSession(accountID int) (Session, error) // DeleteSession removes a session record from the db DeleteSession(sessionKey string) error // ExtendAndFetchSessionAccount fetches an account and session data from the db ExtendAndFetchSessionAccount(sessionKey string, expirationDuration time.Duration) (Account, Session, error) // Close closes the db connection Close() error }
StorageService stores eapp related data
type Submission ¶ added in v0.5.3
type Submission struct { PayloadAdditionalComments Payload `json:"AdditionalComments" sql:"-"` PayloadGeneral Payload `json:"General" sql:"-"` PayloadMedical Payload `json:"Medical" sql:"-"` PayloadCredit Payload `json:"Credit" sql:"-"` PayloadAttachments Payload `json:"Attachments" sql:"-"` AdditionalComments *SubmissionAdditionalComments `json:"-" sql:"-"` General *SubmissionGeneral `json:"-" sql:"-"` Medical *SubmissionMedical `json:"-" sql:"-"` Credit *SubmissionCredit `json:"-" sql:"-"` Attachments *SubmissionAttachments `json:"-" sql:"-"` }
Submission represents the payload for the submission section.
func (*Submission) Marshal ¶ added in v0.5.3
func (entity *Submission) Marshal() Payload
Marshal to payload structure
func (*Submission) Unmarshal ¶ added in v0.5.3
func (entity *Submission) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubmissionAdditionalComments ¶ added in v0.5.3
type SubmissionAdditionalComments struct { PayloadSignature Payload `json:"Signature" sql:"-"` Signature *Signature `json:"-" sql:"-"` }
SubmissionAdditionalComments represents the payload for the submission additional comments section.
func (*SubmissionAdditionalComments) Marshal ¶ added in v0.5.3
func (entity *SubmissionAdditionalComments) Marshal() Payload
Marshal to payload structure
func (*SubmissionAdditionalComments) Unmarshal ¶ added in v0.5.3
func (entity *SubmissionAdditionalComments) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubmissionAttachments ¶ added in v0.5.3
type SubmissionAttachments struct { PayloadMethod Payload `json:"Method" sql:"-"` Method *Text `json:"-" sql:"-"` }
SubmissionAttachments represents the payload for the submission attachments section.
func (*SubmissionAttachments) Marshal ¶ added in v0.5.3
func (entity *SubmissionAttachments) Marshal() Payload
Marshal to payload structure
func (*SubmissionAttachments) Unmarshal ¶ added in v0.5.3
func (entity *SubmissionAttachments) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubmissionCredit ¶ added in v0.5.3
type SubmissionCredit struct { PayloadSignature Payload `json:"Signature" sql:"-"` Signature *Signature `json:"-" sql:"-"` }
SubmissionCredit represents the payload for the submission credit release section.
func (*SubmissionCredit) Marshal ¶ added in v0.5.3
func (entity *SubmissionCredit) Marshal() Payload
Marshal to payload structure
func (*SubmissionCredit) Unmarshal ¶ added in v0.5.3
func (entity *SubmissionCredit) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubmissionGeneral ¶ added in v0.5.3
type SubmissionGeneral struct { PayloadSignature Payload `json:"Signature" sql:"-"` Signature *Signature `json:"-" sql:"-"` }
SubmissionGeneral represents the payload for the submission general release section.
func (*SubmissionGeneral) Marshal ¶ added in v0.5.3
func (entity *SubmissionGeneral) Marshal() Payload
Marshal to payload structure
func (*SubmissionGeneral) Unmarshal ¶ added in v0.5.3
func (entity *SubmissionGeneral) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubmissionMedical ¶ added in v0.5.3
type SubmissionMedical struct { PayloadSignature Payload `json:"Signature" sql:"-"` Signature *Signature `json:"-" sql:"-"` }
SubmissionMedical represents the payload for the submission medical release section.
func (*SubmissionMedical) Marshal ¶ added in v0.5.3
func (entity *SubmissionMedical) Marshal() Payload
Marshal to payload structure
func (*SubmissionMedical) Unmarshal ¶ added in v0.5.3
func (entity *SubmissionMedical) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceAlcoholAdditional ¶ added in v0.5.3
type SubstanceAlcoholAdditional struct { PayloadReceivedTreatment Payload `json:"ReceivedTreatment" sql:"-"` PayloadList Payload `json:"List" sql:"-"` ReceivedTreatment *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceAlcoholAdditional represents the payload for the substance alcohol additional section.
func (*SubstanceAlcoholAdditional) ClearNoBranches ¶
func (entity *SubstanceAlcoholAdditional) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceAlcoholAdditional) Marshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholAdditional) Marshal() Payload
Marshal to payload structure
func (*SubstanceAlcoholAdditional) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholAdditional) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceAlcoholNegative ¶ added in v0.5.3
type SubstanceAlcoholNegative struct { PayloadHasImpacts Payload `json:"HasImpacts" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasImpacts *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceAlcoholNegative represents the payload for the substance alcohol negative section.
func (*SubstanceAlcoholNegative) ClearNoBranches ¶
func (entity *SubstanceAlcoholNegative) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceAlcoholNegative) Marshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholNegative) Marshal() Payload
Marshal to payload structure
func (*SubstanceAlcoholNegative) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholNegative) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceAlcoholOrdered ¶ added in v0.5.3
type SubstanceAlcoholOrdered struct { PayloadHasBeenOrdered Payload `json:"HasBeenOrdered" sql:"-"` PayloadList Payload `json:"List" sql:"-"` HasBeenOrdered *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceAlcoholOrdered represents the payload for the substance alcholo ordered section.
func (*SubstanceAlcoholOrdered) ClearNoBranches ¶
func (entity *SubstanceAlcoholOrdered) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceAlcoholOrdered) Marshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholOrdered) Marshal() Payload
Marshal to payload structure
func (*SubstanceAlcoholOrdered) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholOrdered) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceAlcoholVoluntary ¶ added in v0.5.3
type SubstanceAlcoholVoluntary struct { PayloadSoughtTreatment Payload `json:"SoughtTreatment" sql:"-"` PayloadList Payload `json:"List" sql:"-"` SoughtTreatment *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceAlcoholVoluntary represents the payload for the substance alcohol voluntary section.
func (*SubstanceAlcoholVoluntary) ClearNoBranches ¶
func (entity *SubstanceAlcoholVoluntary) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceAlcoholVoluntary) Marshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholVoluntary) Marshal() Payload
Marshal to payload structure
func (*SubstanceAlcoholVoluntary) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceAlcoholVoluntary) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceDrugClearance ¶ added in v0.5.3
type SubstanceDrugClearance struct { PayloadUsedDrugs Payload `json:"UsedDrugs" sql:"-"` PayloadList Payload `json:"List" sql:"-"` UsedDrugs *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceDrugClearance represents the payload for the substance drug clearance section.
func (*SubstanceDrugClearance) ClearNoBranches ¶
func (entity *SubstanceDrugClearance) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceDrugClearance) Marshal ¶ added in v0.5.3
func (entity *SubstanceDrugClearance) Marshal() Payload
Marshal to payload structure
func (*SubstanceDrugClearance) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceDrugClearance) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceDrugMisuse ¶ added in v0.5.3
type SubstanceDrugMisuse struct { PayloadUsedDrugs Payload `json:"MisusedDrugs" sql:"-"` PayloadList Payload `json:"List" sql:"-"` UsedDrugs *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceDrugMisuse represents the payload for the substance drug misuse section.
func (*SubstanceDrugMisuse) ClearNoBranches ¶
func (entity *SubstanceDrugMisuse) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceDrugMisuse) Marshal ¶ added in v0.5.3
func (entity *SubstanceDrugMisuse) Marshal() Payload
Marshal to payload structure
func (*SubstanceDrugMisuse) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceDrugMisuse) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceDrugOrdered ¶ added in v0.5.3
type SubstanceDrugOrdered struct { PayloadTreatmentOrdered Payload `json:"TreatmentOrdered" sql:"-"` PayloadList Payload `json:"List" sql:"-"` TreatmentOrdered *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceDrugOrdered represents the payload for the substance drug ordered section.
func (*SubstanceDrugOrdered) ClearNoBranches ¶
func (entity *SubstanceDrugOrdered) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceDrugOrdered) Marshal ¶ added in v0.5.3
func (entity *SubstanceDrugOrdered) Marshal() Payload
Marshal to payload structure
func (*SubstanceDrugOrdered) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceDrugOrdered) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceDrugPublicSafety ¶ added in v0.5.3
type SubstanceDrugPublicSafety struct { PayloadUsedDrugs Payload `json:"UsedDrugs" sql:"-"` PayloadList Payload `json:"List" sql:"-"` UsedDrugs *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceDrugPublicSafety represents the payload for the substance drug public safety section.
func (*SubstanceDrugPublicSafety) ClearNoBranches ¶
func (entity *SubstanceDrugPublicSafety) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceDrugPublicSafety) Marshal ¶ added in v0.5.3
func (entity *SubstanceDrugPublicSafety) Marshal() Payload
Marshal to payload structure
func (*SubstanceDrugPublicSafety) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceDrugPublicSafety) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceDrugPurchase ¶ added in v0.5.3
type SubstanceDrugPurchase struct { PayloadInvolved Payload `json:"Involved" sql:"-"` PayloadList Payload `json:"List" sql:"-"` Involved *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceDrugPurchase represents the payload for the substance drug purchase section.
func (*SubstanceDrugPurchase) ClearNoBranches ¶
func (entity *SubstanceDrugPurchase) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceDrugPurchase) Marshal ¶ added in v0.5.3
func (entity *SubstanceDrugPurchase) Marshal() Payload
Marshal to payload structure
func (*SubstanceDrugPurchase) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceDrugPurchase) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceDrugUsage ¶ added in v0.5.3
type SubstanceDrugUsage struct { PayloadUsedDrugs Payload `json:"UsedDrugs" sql:"-"` PayloadList Payload `json:"List" sql:"-"` UsedDrugs *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceDrugUsage represents the payload for the substance drug usage section.
func (*SubstanceDrugUsage) ClearNoBranches ¶
func (entity *SubstanceDrugUsage) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceDrugUsage) Marshal ¶ added in v0.5.3
func (entity *SubstanceDrugUsage) Marshal() Payload
Marshal to payload structure
func (*SubstanceDrugUsage) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceDrugUsage) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type SubstanceDrugVoluntary ¶ added in v0.5.3
type SubstanceDrugVoluntary struct { PayloadTreatmentVoluntary Payload `json:"TreatmentVoluntary" sql:"-"` PayloadList Payload `json:"List" sql:"-"` TreatmentVoluntary *Branch `json:"-"` List *Collection `json:"-"` }
SubstanceDrugVoluntary represents the payload for the substance drug voluntary section.
func (*SubstanceDrugVoluntary) ClearNoBranches ¶
func (entity *SubstanceDrugVoluntary) ClearNoBranches() error
ClearNoBranches clears the "no" answers on application rejection
func (*SubstanceDrugVoluntary) Marshal ¶ added in v0.5.3
func (entity *SubstanceDrugVoluntary) Marshal() Payload
Marshal to payload structure
func (*SubstanceDrugVoluntary) Unmarshal ¶ added in v0.5.3
func (entity *SubstanceDrugVoluntary) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Supervisor ¶ added in v0.5.3
type Supervisor struct { PayloadSupervisorName Payload `json:"SupervisorName" sql:"-"` PayloadTitle Payload `json:"Title" sql:"-"` PayloadEmail Payload `json:"Email" sql:"-"` PayloadEmailNotApplicable Payload `json:"EmailNotApplicable" sql:"-"` PayloadAddress Payload `json:"Address" sql:"-"` PayloadTelephone Payload `json:"Telephone" sql:"-"` SupervisorName *Text `json:"-"` Title *Text `json:"-"` Email *Email `json:"-"` EmailNotApplicable *NotApplicable `json:"-"` Address *Location `json:"-"` Telephone *Telephone `json:"-"` }
Supervisor is a basic input.
func (*Supervisor) Marshal ¶ added in v0.5.3
func (entity *Supervisor) Marshal() Payload
Marshal to payload structure
func (*Supervisor) Unmarshal ¶ added in v0.5.3
func (entity *Supervisor) Unmarshal(raw []byte) error
Unmarshal bytes in to the entity properties.
type Telephone ¶ added in v0.5.3
type Telephone struct { ID int `json:"-"` TimeOfDay string `json:"timeOfDay"` Type string `json:"type"` NumberType string `json:"numberType"` Number string `json:"number"` Extension string `json:"extension"` NoNumber bool `json:"noNumber"` }
Telephone is a basic input.
type Text ¶ added in v0.5.3
Text is a basic input.
type Textarea ¶ added in v0.5.3
Textarea is a basic input.
type Transmission ¶ added in v0.5.3
type Transmission struct { ID int AccountID int Raw []byte RequestKey string AgencyKey int Status string Created time.Time Modified time.Time }
Transmission record of application being sent to external system for additional processing.
func (*Transmission) Find ¶ added in v0.5.3
func (transmission *Transmission) Find(context DatabaseService) error
Find is not used for transmissions. Please use the `Get` method.
func (*Transmission) Get ¶ added in v0.5.3
func (transmission *Transmission) Get(context DatabaseService) error
Get transmission record from the database.
func (*Transmission) Save ¶ added in v0.5.3
func (transmission *Transmission) Save(context DatabaseService) error
Save transmission record to the database.
type Treatment ¶ added in v0.5.3
type Treatment struct { PayloadName Payload `json:"Name" sql:"-"` PayloadPhone Payload `json:"Phone" sql:"-"` PayloadAddress Payload `json:"Address" sql:"-"` Name *Text `json:"-"` Phone *Telephone `json:"-"` Address *Location `json:"-"` }
Treatment is a basic structure.
type ValidationResult ¶ added in v0.5.3
type ValidationResult interface {
Result(fieldname string) interface{}
}
ValidationResult is an interface to be used by errors that return a properly formatted struct to be used to send for client-side validation requests.
type XMLService ¶ added in v0.5.3
type XMLService interface {
PackageXML(app Application) (template.HTML, error)
}
XMLService represents a basic interface to XML related functionality.
Source Files ¶
- account.go
- additionalcomments.go
- application.go
- attachment.go
- audience.go
- basicauth_membership.go
- benefit.go
- branch.go
- checkbox.go
- checkboxgroup.go
- citizenship.go
- civilunion.go
- clearancelevel.go
- collection.go
- contacts.go
- coowners.go
- country.go
- database.go
- datecontrol.go
- daterange.go
- email.go
- employmentactivity.go
- entity.go
- errors.go
- financial.go
- foreign.go
- foreignborndocument.go
- geo.go
- height.go
- history.go
- identification.go
- legal.go
- location.go
- log.go
- migration.go
- military.go
- name.go
- notapplicable.go
- number.go
- payload.go
- pdf.go
- physicaladdress.go
- psychological.go
- radio.go
- reasonleft.go
- relationships.go
- saml.go
- section.go
- sentence.go
- serializer.go
- session.go
- settings.go
- signature.go
- ssn.go
- store.go
- submission.go
- substance.go
- supervisor.go
- telephone.go
- text.go
- textarea.go
- transform.go
- transmission.go
- treatment.go
- xml.go