Crate bears_species

Crate bears_species 

Source

Structs§

AffiliateLevel
AmneIter
Returns an iterator over the Mne struct for the AMNE dataset. Used to create API calls with SeriesID, State and Years set to “ALL”. Includes footnotes.
AnnotationMissing
ApiMetadata
BTreeKeyMissing
BadMetric
BadScale
BeaErr
BeaResponse
BoolInvalid
BoolOptions
Csv
The Csv struct contains error information associated with the csv crate.
Currency
The Currency type represents BEA values by embedding the raw data value with contextual metadata related to unit multipliers and currency standard. Prevents misinterpretation of raw data values and facilitates conversion between value types.
DatasetDetails
The DatasetDetails type represents dataset descriptions in a BEA response. This data type is an intermediary between the serde_json::Value representation and the strongly-typed internal representation, implemented using the lowly String.
DatasetMissing
Datasets
The Datasets type is a thin wrapper around a vector of DatasetDetails.
DeriveFromStr
DirectionOfInvestment
EnvError
FixedAssetData
FixedAssets
Frequencies
FromStrError
GdpByIndustry
GdpData
GdpData represents the Data portion of the Results from a BEA response. These portions of the response have corresponding internal library representations, Data, Results and BeaResponse respectively. This is the data type contained within the [Data::GdpData] variant.
GdpDatum
Return value format associated with the Dataset::GDPbyIndustry variant.
GdpTables
Returns an iterator over table ids in the GdpByIndustry struct. Used to create API calls with Industry, Frequency and Years set to “ALL”.
Iip
IipData
IipInvestments
Returns an iterator over investments in the Iip struct. Used to create API calls with Component, Frequency and Years set to “ALL”.
InputOutput
InputOutputCode
Parent enum for types of InputOutput row and column codes.
InputOutputData
InputOutputIterator
This iterator returns all values for table id and years regardless of whether the user subsets the InputOutput struct that generates the iterator.
Integer
IntegerInvalid
IntegerOptions
IntlServSta
IntlServTrade
IoError
Ita
ItaData
ItaDatum
ItaFrequencies
ItaIterator
This iterator returns all values for indicator, frequency, and years regardless of whether the user subsets the Ita struct that generates the iterator.
Jiff
JsonParseError
KeyMissing
Metadata
Millions
Mismatch
Mne
MneDiData
MneDoi
MneIter
Returns an iterator over the Mne struct for Direct Investment data. Used to create API calls with SeriesID, State and Years set to “ALL”. Includes footnotes.
NaicsItem
NaicsItems
NiUnderlyingDetail
Nipa
NipaData
NipaFrequency
NipaIterator
NipaRange
NipaRangeIterator
NipaRanges
NipaShowMillions
NipaTable
NipaYear
The NipaYear struct contains fields associated with the BEA response for Year parameter values in the NIPA dataset. The fields define ranges of years for which table data is available for a given frequency (annual, monthly or quartelry), using the pattern first_{frequency}_year and last_{frequency}_year.
Nom
NotArray
NotFloat
NotInteger
NotObject
NotParameterName
NotQuarter
Note
Notes
OwnershipInvalid
OwnershipLevel
Parameter
ParameterFields
ParameterValueTableVariant
ParameterValues
Thin wrapper around a vector of type ParameterValueTable.
Parameters
Thin wrapper around a vector of type Parameter.
ParseFloat
ParseInt
ParseInteger
Progress
RateLimit
Regional
RequestParameter
RequestParameters
ReqwestError
RowCodeMissing
SerdeJson
State
TableName
TODO: Used in Fixed Assets and Regional key sets.
UrlParseError
VariantMissing
Year
YearInvalid
YearOptions
YearRange

Enums§

AffiliateKind
Affiliation
Affiliation for international services and trade data
AnnotatedInteger
Annotation
AocSta
Area or Country Statistical Area enum representing geographic regions and countries
AreaOrCountry
BeaErrorKind
Channel
Channels for service trade and affiliate activity
Classification
Component
Represents different types of components used for position changes in financial accounts.
Data
Dataset
The Dataset enum contains variants for each dataset published by the BEA.
DirectionKind
DI can be Inward or Outward variants, while AMNE can take all values.
FixedAssetLine
Fixed asset line classifications
FixedAssetTable
Footnotes
Frequency
FrequencyOptions
IipIndustry
Industry designations from the IIP dataset.
Indicator
Valid values for the Indicator parameter.
InputOutputTable
Represents different types of input-output tables in an economic analysis framework.
IntegerKind
Investment
ItaFrequency
JsonParseErrorKind
Measure
The Measure enum represents variants of the Classification Unit in the FixedAssets and IIP datasets.
Method
The variants of the Method enum represent different valid inputs for the METHOD parameter when calling into the BEA REST API.
Metric
Metrics associated with the Fixed Assets dataset (Dataset::FixedAssets)
MillionsOptions
MneKind
Naics
Parent enum for types of NAICS codes.
NaicsCategory
NAICS Category codes
NaicsIndustry
North American Industry Classification System (NAICS) industry codes
NaicsInputOutput
NaicsSector
Represents the North American Industry Classification System (NAICS) sectors.
NaicsSubcategory
Represents NAICS subcategories
NaicsSubsector
NAICS Subsector definitions based on North American Industry Classification System
NaicsSupplement
The MNE dataset includes row numbers for summary statistics over industries that do not correspond to valid NAICS codes. The NaicsSupplement type accommodates these additional categories.
NipaTableName
Represents the various table types available in the National Income and Product Accounts (NIPA). Each variant corresponds to a specific NIPA table with a unique identifier.
OwnershipKind
ParameterName
Each variant of the ParameterName enum represents a valid input for the PARAMETERNAME parameter of the BEA REST API.
ParameterValueTable
Results
RowCode
Scale
Scale factor associated with a currency value.
SelectionKind
SelectionSet
Service
Represents values for the TypeOfService parameter in the IntlServTrade dataset.
Set
StateKind
TradeDirection
Trade direction for international services and trade data
ValueKind
Variants contain different data value types, with methods to retrieve values by type.
YearKind

Functions§

date_by_period
deserialize_bool
Custom handling of bool deserialization to match BEA.
from_csv
Generic function to deserialize data types from a CSV file. Called by methods to avoid code duplication.
json_bool
Converts a serde_json::Value to a bool based on BEA data conventions. Called by map_to_bool.
json_str
Converts a serde_json::Value to a String. Called by map_to_string.
map_to_bool
Convenience function for when we expect a boolean value stored as a JSON string.
map_to_float
Convenience function for when we expect a float stored as a JSON string.
map_to_int
Convenience function for when we expect an integer stored as a JSON string.
map_to_string
Convenience function for when we expect a String value stored as a JSON string.
parse_year
result_to_data
roman_numeral_quarter
Converts Roman numeral notation to a Date from the jiff crate.
to_csv
Generic function to serialize data types into a CSV file. Called by methods to avoid code duplication.
write_json
Takes any type that implements Serialize and writes the output the a json file at path.