module Eddy module Elements # ### Element Summary: # # - Id: 156 # - Name: State or Province Code # - Type: ID # - Min/Max: 2/2 # - Description: Code (Standard State/Province) as defined by appropriate government agency. # # ### Notes: # # - FIXME: Currently only accepts states in the USA and Canada. class E156 < Eddy::Models::Element::ID # @param val [String] (nil) # @param req [String] (nil) # @param ref [String] (nil) # @return [void] def initialize(val: nil, req: nil, ref: nil) @id = "156" @name = "State or Province Code" @description = "(Standard State/Province) as defined by appropriate government agency." super( min: 2, max: 2, req: req, ref: ref, val: val, ) end # @return [Array] def code_list() return [ # United States "AL", "AK", "AZ", "AR", "CA", "CO", "CT", "DE", "DC", "FL", "GA", "HI", "ID", "IL", "IN", "IA", "KS", "KY", "LA", "ME", "MD", "MA", "MI", "MN", "MS", "MO", "MT", "NE", "NV", "NH", "NJ", "NM", "NY", "NC", "ND", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VT", "VA", "WA", "WV", "WI", "WY", # Canada "AB", "BC", "MB", "NB", "NL", "NS", "NT", "NU", "ON", "PE", "QC", "SK", "YT", ] end end end end