Class: Ingenico::Direct::SDK::DataObject
- Inherits:
-
Object
- Object
- Ingenico::Direct::SDK::DataObject
- Defined in:
- lib/ingenico/direct/sdk/data_object.rb
Overview
Base class for all SDK data objects, supports marshalling and unmarshalling the data object to and from JSON.
Direct Known Subclasses
Ingenico::Direct::SDK::Domain::APIError, Ingenico::Direct::SDK::Domain::AccountOnFile, Ingenico::Direct::SDK::Domain::AccountOnFileAttribute, Ingenico::Direct::SDK::Domain::AccountOnFileDisplayHints, Ingenico::Direct::SDK::Domain::AdditionalOrderInput, Ingenico::Direct::SDK::Domain::Address, Ingenico::Direct::SDK::Domain::AddressPersonal, Ingenico::Direct::SDK::Domain::AirlineData, Ingenico::Direct::SDK::Domain::AirlineFlightLeg, Ingenico::Direct::SDK::Domain::AirlinePassenger, Ingenico::Direct::SDK::Domain::AmountBreakdown, Ingenico::Direct::SDK::Domain::AmountOfMoney, Ingenico::Direct::SDK::Domain::BrowserData, Ingenico::Direct::SDK::Domain::CancelPaymentResponse, Ingenico::Direct::SDK::Domain::Capture, Ingenico::Direct::SDK::Domain::CaptureOutput, Ingenico::Direct::SDK::Domain::CapturePaymentRequest, Ingenico::Direct::SDK::Domain::CaptureResponse, Ingenico::Direct::SDK::Domain::CaptureStatusOutput, Ingenico::Direct::SDK::Domain::CapturesResponse, Ingenico::Direct::SDK::Domain::Card, Ingenico::Direct::SDK::Domain::CardEssentials, Ingenico::Direct::SDK::Domain::CardFraudResults, Ingenico::Direct::SDK::Domain::CardPaymentMethodSpecificInput, Ingenico::Direct::SDK::Domain::CardPaymentMethodSpecificInputBase, Ingenico::Direct::SDK::Domain::CardPaymentMethodSpecificOutput, Ingenico::Direct::SDK::Domain::CardPayoutMethodSpecificInput, Ingenico::Direct::SDK::Domain::CardRecurrenceDetails, Ingenico::Direct::SDK::Domain::CardWithoutCvv, Ingenico::Direct::SDK::Domain::CompanyInformation, Ingenico::Direct::SDK::Domain::CompletePaymentCardPaymentMethodSpecificInput, Ingenico::Direct::SDK::Domain::CompletePaymentRequest, Ingenico::Direct::SDK::Domain::CompletePaymentResponse, Ingenico::Direct::SDK::Domain::ContactDetails, Ingenico::Direct::SDK::Domain::CreateHostedCheckoutRequest, Ingenico::Direct::SDK::Domain::CreateHostedCheckoutResponse, Ingenico::Direct::SDK::Domain::CreateHostedTokenizationRequest, Ingenico::Direct::SDK::Domain::CreateHostedTokenizationResponse, Ingenico::Direct::SDK::Domain::CreatePaymentRequest, Ingenico::Direct::SDK::Domain::CreatePaymentResponse, Ingenico::Direct::SDK::Domain::CreatePayoutRequest, Ingenico::Direct::SDK::Domain::CreateTokenRequest, Ingenico::Direct::SDK::Domain::CreatedPaymentOutput, Ingenico::Direct::SDK::Domain::CreatedTokenResponse, Ingenico::Direct::SDK::Domain::Customer, Ingenico::Direct::SDK::Domain::CustomerAccount, Ingenico::Direct::SDK::Domain::CustomerAccountAuthentication, Ingenico::Direct::SDK::Domain::CustomerDevice, Ingenico::Direct::SDK::Domain::CustomerPaymentActivity, Ingenico::Direct::SDK::Domain::CustomerToken, Ingenico::Direct::SDK::Domain::DecryptedPaymentData, Ingenico::Direct::SDK::Domain::DirectoryEntry, Ingenico::Direct::SDK::Domain::EmptyValidator, Ingenico::Direct::SDK::Domain::ErrorResponse, Ingenico::Direct::SDK::Domain::ExternalCardholderAuthenticationData, Ingenico::Direct::SDK::Domain::ExternalTokenLinked, Ingenico::Direct::SDK::Domain::FixedListValidator, Ingenico::Direct::SDK::Domain::FraudFields, Ingenico::Direct::SDK::Domain::FraudResults, Ingenico::Direct::SDK::Domain::GPayThreeDSecure, Ingenico::Direct::SDK::Domain::GetHostedCheckoutResponse, Ingenico::Direct::SDK::Domain::GetHostedTokenizationResponse, Ingenico::Direct::SDK::Domain::GetIINDetailsRequest, Ingenico::Direct::SDK::Domain::GetIINDetailsResponse, Ingenico::Direct::SDK::Domain::GetPaymentProductGroupsResponse, Ingenico::Direct::SDK::Domain::GetPaymentProductsResponse, Ingenico::Direct::SDK::Domain::GiftCardPurchase, Ingenico::Direct::SDK::Domain::HostedCheckoutSpecificInput, Ingenico::Direct::SDK::Domain::HostedCheckoutSpecificOutput, Ingenico::Direct::SDK::Domain::IINDetail, Ingenico::Direct::SDK::Domain::LabelTemplateElement, Ingenico::Direct::SDK::Domain::LengthValidator, Ingenico::Direct::SDK::Domain::LineItem, Ingenico::Direct::SDK::Domain::LineItemInvoiceData, Ingenico::Direct::SDK::Domain::LoanRecipient, Ingenico::Direct::SDK::Domain::LodgingData, Ingenico::Direct::SDK::Domain::MerchantAction, Ingenico::Direct::SDK::Domain::MobilePaymentData, Ingenico::Direct::SDK::Domain::MobilePaymentMethodHostedCheckoutSpecificInput, Ingenico::Direct::SDK::Domain::MobilePaymentMethodSpecificInput, Ingenico::Direct::SDK::Domain::MobilePaymentMethodSpecificOutput, Ingenico::Direct::SDK::Domain::MobilePaymentProduct320SpecificInput, Ingenico::Direct::SDK::Domain::OperationOutput, Ingenico::Direct::SDK::Domain::Order, Ingenico::Direct::SDK::Domain::OrderLineDetails, Ingenico::Direct::SDK::Domain::OrderReferences, Ingenico::Direct::SDK::Domain::OrderStatusOutput, Ingenico::Direct::SDK::Domain::OrderTypeInformation, Ingenico::Direct::SDK::Domain::PaymentAccountOnFile, Ingenico::Direct::SDK::Domain::PaymentContext, Ingenico::Direct::SDK::Domain::PaymentCreationOutput, Ingenico::Direct::SDK::Domain::PaymentDetailsResponse, Ingenico::Direct::SDK::Domain::PaymentErrorResponse, Ingenico::Direct::SDK::Domain::PaymentOutput, Ingenico::Direct::SDK::Domain::PaymentProduct, Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificInput, Ingenico::Direct::SDK::Domain::PaymentProduct130SpecificThreeDSecure, Ingenico::Direct::SDK::Domain::PaymentProduct302SpecificData, Ingenico::Direct::SDK::Domain::PaymentProduct320SpecificData, Ingenico::Direct::SDK::Domain::PaymentProduct5100SpecificInput, Ingenico::Direct::SDK::Domain::PaymentProduct5402SpecificOutput, Ingenico::Direct::SDK::Domain::PaymentProduct5500SpecificOutput, Ingenico::Direct::SDK::Domain::PaymentProduct771SpecificOutput, Ingenico::Direct::SDK::Domain::PaymentProduct840CustomerAccount, Ingenico::Direct::SDK::Domain::PaymentProduct840SpecificOutput, Ingenico::Direct::SDK::Domain::PaymentProductDisplayHints, Ingenico::Direct::SDK::Domain::PaymentProductField, Ingenico::Direct::SDK::Domain::PaymentProductFieldDataRestrictions, Ingenico::Direct::SDK::Domain::PaymentProductFieldDisplayElement, Ingenico::Direct::SDK::Domain::PaymentProductFieldDisplayHints, Ingenico::Direct::SDK::Domain::PaymentProductFieldFormElement, Ingenico::Direct::SDK::Domain::PaymentProductFieldTooltip, Ingenico::Direct::SDK::Domain::PaymentProductFieldValidators, Ingenico::Direct::SDK::Domain::PaymentProductFilter, Ingenico::Direct::SDK::Domain::PaymentProductFiltersHostedCheckout, Ingenico::Direct::SDK::Domain::PaymentProductGroup, Ingenico::Direct::SDK::Domain::PaymentProductNetworksResponse, Ingenico::Direct::SDK::Domain::PaymentReferences, Ingenico::Direct::SDK::Domain::PaymentResponse, Ingenico::Direct::SDK::Domain::PaymentStatusOutput, Ingenico::Direct::SDK::Domain::PayoutErrorResponse, Ingenico::Direct::SDK::Domain::PayoutOutput, Ingenico::Direct::SDK::Domain::PayoutResponse, Ingenico::Direct::SDK::Domain::PayoutResult, Ingenico::Direct::SDK::Domain::PayoutStatusOutput, Ingenico::Direct::SDK::Domain::PersonalInformation, Ingenico::Direct::SDK::Domain::PersonalInformationToken, Ingenico::Direct::SDK::Domain::PersonalName, Ingenico::Direct::SDK::Domain::PersonalNameToken, Ingenico::Direct::SDK::Domain::ProductDirectory, Ingenico::Direct::SDK::Domain::ProtectionEligibility, Ingenico::Direct::SDK::Domain::RangeValidator, Ingenico::Direct::SDK::Domain::RedirectData, Ingenico::Direct::SDK::Domain::RedirectPaymentMethodSpecificInput, Ingenico::Direct::SDK::Domain::RedirectPaymentMethodSpecificOutput, Ingenico::Direct::SDK::Domain::RedirectPaymentProduct809SpecificInput, Ingenico::Direct::SDK::Domain::RedirectPaymentProduct840SpecificInput, Ingenico::Direct::SDK::Domain::RedirectionData, Ingenico::Direct::SDK::Domain::RefundCardMethodSpecificOutput, Ingenico::Direct::SDK::Domain::RefundEWalletMethodSpecificOutput, Ingenico::Direct::SDK::Domain::RefundErrorResponse, Ingenico::Direct::SDK::Domain::RefundMobileMethodSpecificOutput, Ingenico::Direct::SDK::Domain::RefundOutput, Ingenico::Direct::SDK::Domain::RefundPaymentProduct840CustomerAccount, Ingenico::Direct::SDK::Domain::RefundPaymentProduct840SpecificOutput, Ingenico::Direct::SDK::Domain::RefundRedirectMethodSpecificOutput, Ingenico::Direct::SDK::Domain::RefundRequest, Ingenico::Direct::SDK::Domain::RefundResponse, Ingenico::Direct::SDK::Domain::RefundsResponse, Ingenico::Direct::SDK::Domain::RegularExpressionValidator, Ingenico::Direct::SDK::Domain::SepaDirectDebitPaymentMethodSpecificOutput, Ingenico::Direct::SDK::Domain::SessionRequest, Ingenico::Direct::SDK::Domain::SessionResponse, Ingenico::Direct::SDK::Domain::Shipping, Ingenico::Direct::SDK::Domain::ShoppingCart, Ingenico::Direct::SDK::Domain::ShoppingCartExtension, Ingenico::Direct::SDK::Domain::TestConnection, Ingenico::Direct::SDK::Domain::ThreeDSecure, Ingenico::Direct::SDK::Domain::ThreeDSecureBase, Ingenico::Direct::SDK::Domain::ThreeDSecureData, Ingenico::Direct::SDK::Domain::ThreeDSecureResults, Ingenico::Direct::SDK::Domain::TokenCard, Ingenico::Direct::SDK::Domain::TokenCardData, Ingenico::Direct::SDK::Domain::TokenCardSpecificInput, Ingenico::Direct::SDK::Domain::TokenData, Ingenico::Direct::SDK::Domain::TokenEWallet, Ingenico::Direct::SDK::Domain::TokenResponse, Ingenico::Direct::SDK::Domain::ValueMappingElement, MetaDataProvider::ServerMetaInfo, Webhooks::WebhooksEvent
Class Method Summary collapse
-
.new_from_hash(hash) ⇒ Object
Create a new instance of this object (DataObject or descendant) from a hash containing attribute values in camelCase.
Instance Method Summary collapse
-
#from_hash(hash) ⇒ Object
Set attributes from values in parameter hash.
-
#to_h ⇒ Hash
Returns a hash representation of the DataObject.
Class Method Details
.new_from_hash(hash) ⇒ Object
Create a new instance of this object (DataObject or descendant) from a hash containing attribute values in camelCase. Note that the hash contains Strings as keys instead of more commonly used tokens.
20 21 22 23 24 |
# File 'lib/ingenico/direct/sdk/data_object.rb', line 20 def self.new_from_hash(hash) obj = self.new obj.from_hash(hash) obj end |
Instance Method Details
#from_hash(hash) ⇒ Object
Set attributes from values in parameter hash. Should be overridden by descendants in order to properly restore their attributes from the hash. Note that the hash contains Strings as keys instead of more commonly used tokens.
29 30 |
# File 'lib/ingenico/direct/sdk/data_object.rb', line 29 def from_hash(hash) end |
#to_h ⇒ Hash
Returns a hash representation of the DataObject. The hash contains camelCase representations of the variables, and their values. Should be overridden to add all instance variables of the object.
13 14 15 |
# File 'lib/ingenico/direct/sdk/data_object.rb', line 13 def to_h {} end |