mencoro 1.0.1 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +41 -5
- data/docs/AccountApi.md +1 -1
- data/docs/AnalyticsApi.md +96 -86
- data/docs/AsyncJobResource.md +3 -1
- data/docs/AsyncJobResourceError.md +20 -0
- data/docs/BillingApi.md +1 -1
- data/docs/CitedSourceRow.md +32 -0
- data/docs/CitedSourcesResponse.md +20 -0
- data/docs/ClusterBreakdownRow.md +82 -0
- data/docs/ClustersApi.md +74 -0
- data/docs/CompetitorCoOccurrenceResponse.md +18 -0
- data/docs/CompetitorCoOccurrenceRow.md +36 -0
- data/docs/CompetitorShareOfVoice.md +20 -0
- data/docs/CreateInvitation201Response.md +4 -0
- data/docs/CreateInvitationRequest.md +3 -1
- data/docs/CreateInvitationRequestProjectAccess.md +20 -0
- data/docs/DiscoveryApi.md +1 -1
- data/docs/GetMeStats200ResponseProjects.md +1 -1
- data/docs/GetOrganizationOverview200ResponseAggregate.md +1 -1
- data/docs/GetOrganizationOverview200ResponseProjectsInner.md +8 -2
- data/docs/GetOrganizationStats200ResponseInvitations.md +1 -1
- data/docs/GetOrganizationStats200ResponseMembers.md +1 -1
- data/docs/GetOrganizationStats200ResponseProjects.md +1 -1
- data/docs/InvitationResource.md +5 -1
- data/docs/JobsApi.md +1 -1
- data/docs/KeywordListingResource.md +12 -10
- data/docs/KeywordListingResourceCarriedPositions.md +24 -0
- data/docs/KeywordListingResourceCarriedPositionsSerp.md +20 -0
- data/docs/ListProjects200Response.md +1 -1
- data/docs/MemberResource.md +5 -1
- data/docs/MembersApi.md +78 -0
- data/docs/MentionMatchResource.md +44 -0
- data/docs/MentionSampleResponse.md +46 -0
- data/docs/MentionTypeCounts.md +26 -0
- data/docs/OrganizationsApi.md +3 -3
- data/docs/PerCompetitorSentiment.md +30 -0
- data/docs/PerEngineSentiment.md +28 -0
- data/docs/PerEntityMetrics.md +32 -0
- data/docs/PositionDistributionBucket.md +20 -0
- data/docs/ProjectMentionMixResponse.md +22 -0
- data/docs/ProjectMentionSamplesResponse.md +20 -0
- data/docs/ProjectRankTrackingClusterBreakdown.md +20 -0
- data/docs/ProjectRankTrackingStats.md +96 -0
- data/docs/ProjectRankTrackingTimeSeries.md +20 -0
- data/docs/ProjectSentimentBreakdown.md +20 -0
- data/docs/ProjectedMonthlyChecksResource.md +2 -2
- data/docs/ProjectsApi.md +76 -2
- data/docs/SearchTrackedQueryMentionMatches200Response.md +20 -0
- data/docs/SearchTrackedQuerySerpMatches200Response.md +20 -0
- data/docs/SerpMatchResource.md +30 -0
- data/docs/SetMemberProjectAccessRequest.md +20 -0
- data/docs/SubscriptionResource.md +1 -1
- data/docs/TimeSeriesPoint.md +22 -0
- data/docs/TrackedQueriesApi.md +175 -3
- data/docs/TrackedQueryCountResource.md +1 -1
- data/docs/TrackedQueryMoverRow.md +58 -0
- data/docs/TrackedQueryMoversResponse.md +22 -0
- data/docs/TrackedQueryRankTrackingTimeSeries.md +20 -0
- data/docs/TrackedQueryUsageResource.md +1 -1
- data/lib/mencoro/api/account_api.rb +3 -3
- data/lib/mencoro/api/analytics_api.rb +103 -85
- data/lib/mencoro/api/billing_api.rb +3 -3
- data/lib/mencoro/api/captures_api.rb +2 -2
- data/lib/mencoro/api/clusters_api.rb +76 -1
- data/lib/mencoro/api/discovery_api.rb +3 -3
- data/lib/mencoro/api/invitations_api.rb +1 -1
- data/lib/mencoro/api/jobs_api.rb +3 -3
- data/lib/mencoro/api/members_api.rb +95 -1
- data/lib/mencoro/api/organization_operations_api.rb +1 -1
- data/lib/mencoro/api/organizations_api.rb +7 -7
- data/lib/mencoro/api/projects_api.rb +80 -5
- data/lib/mencoro/api/tracked_queries_api.rb +220 -8
- data/lib/mencoro/api_client.rb +2 -2
- data/lib/mencoro/api_error.rb +1 -1
- data/lib/mencoro/api_model_base.rb +1 -1
- data/lib/mencoro/configuration.rb +1 -1
- data/lib/mencoro/models/accepted_job_resource.rb +1 -1
- data/lib/mencoro/models/ai_response_report_resource.rb +1 -1
- data/lib/mencoro/models/ai_response_resource.rb +1 -1
- data/lib/mencoro/models/apply_clustering_job_outcome.rb +1 -1
- data/lib/mencoro/models/apply_clustering_job_outcome_clusters_inner.rb +1 -1
- data/lib/mencoro/models/apply_clustering_job_outcome_failed_inner.rb +1 -1
- data/lib/mencoro/models/apply_clustering_job_outcome_skipped_clusters_inner.rb +1 -1
- data/lib/mencoro/models/apply_clustering_job_outcome_successful_inner.rb +1 -1
- data/lib/mencoro/models/async_job_resource.rb +17 -7
- data/lib/mencoro/models/async_job_resource_error.rb +217 -0
- data/lib/mencoro/models/batch_change_tracked_query_check_frequency_request_data.rb +1 -1
- data/lib/mencoro/models/batch_change_tracked_query_passes_request_data.rb +1 -1
- data/lib/mencoro/models/batch_create_query_clusters_outcome.rb +1 -1
- data/lib/mencoro/models/batch_create_query_clusters_outcome_failed_inner.rb +1 -1
- data/lib/mencoro/models/batch_create_query_clusters_outcome_successful_inner.rb +1 -1
- data/lib/mencoro/models/batch_create_query_clusters_request_data.rb +1 -1
- data/lib/mencoro/models/batch_create_tracked_queries_request_data.rb +1 -1
- data/lib/mencoro/models/batch_create_tracked_queries_result_resource.rb +1 -1
- data/lib/mencoro/models/batch_create_tracked_queries_result_resource_failed_inner.rb +1 -1
- data/lib/mencoro/models/batch_create_tracked_queries_result_resource_successful_inner.rb +1 -1
- data/lib/mencoro/models/batch_force_check_tracked_queries200_response.rb +1 -1
- data/lib/mencoro/models/batch_force_check_tracked_queries200_response_failed_inner.rb +1 -1
- data/lib/mencoro/models/batch_pause_tracked_queries200_response.rb +1 -1
- data/lib/mencoro/models/batch_pause_tracked_queries200_response_failed_inner.rb +1 -1
- data/lib/mencoro/models/batch_pause_tracked_queries200_response_successful_inner.rb +1 -1
- data/lib/mencoro/models/batch_resume_tracked_queries200_response.rb +1 -1
- data/lib/mencoro/models/batch_targets_request_data.rb +1 -1
- data/lib/mencoro/models/batch_write_outcome.rb +1 -1
- data/lib/mencoro/models/batch_write_outcome_failed_inner.rb +1 -1
- data/lib/mencoro/models/brand_profile_resource.rb +1 -1
- data/lib/mencoro/models/bulk_add_clusters_to_tracked_queries200_response.rb +1 -1
- data/lib/mencoro/models/bulk_add_clusters_to_tracked_queries_request.rb +1 -1
- data/lib/mencoro/models/bulk_remove_clusters_from_tracked_queries200_response.rb +1 -1
- data/lib/mencoro/models/bulk_remove_clusters_from_tracked_queries_request.rb +1 -1
- data/lib/mencoro/models/change_member_role_request.rb +1 -1
- data/lib/mencoro/models/change_tracked_query_check_frequency_request_data.rb +1 -1
- data/lib/mencoro/models/change_tracked_query_passes_request_data.rb +1 -1
- data/lib/mencoro/models/citation_resource.rb +1 -1
- data/lib/mencoro/models/cited_source_row.rb +298 -0
- data/lib/mencoro/models/cited_sources_response.rb +192 -0
- data/lib/mencoro/models/cluster_breakdown_row.rb +580 -0
- data/lib/mencoro/models/cluster_membership_request_data.rb +1 -1
- data/lib/mencoro/models/competitor_co_occurrence_response.rb +166 -0
- data/lib/mencoro/models/competitor_co_occurrence_row.rb +318 -0
- data/lib/mencoro/models/competitor_resource.rb +1 -1
- data/lib/mencoro/models/competitor_share_of_voice.rb +174 -0
- data/lib/mencoro/models/create_competitor_request.rb +1 -1
- data/lib/mencoro/models/create_invitation200_response.rb +1 -1
- data/lib/mencoro/models/create_invitation201_response.rb +60 -2
- data/lib/mencoro/models/create_invitation_request.rb +15 -5
- data/lib/mencoro/models/create_invitation_request_project_access.rb +201 -0
- data/lib/mencoro/models/create_organization201_response.rb +1 -1
- data/lib/mencoro/models/create_organization_request.rb +1 -1
- data/lib/mencoro/models/create_project_request.rb +1 -1
- data/lib/mencoro/models/create_project_request_competitors_inner.rb +1 -1
- data/lib/mencoro/models/create_query_cluster409_response.rb +1 -1
- data/lib/mencoro/models/create_query_cluster_request.rb +1 -1
- data/lib/mencoro/models/delete_query_cluster200_response.rb +1 -1
- data/lib/mencoro/models/entitlements_resource.rb +1 -1
- data/lib/mencoro/models/get_available_filters200_response.rb +1 -1
- data/lib/mencoro/models/get_available_filters200_response_clusters_inner.rb +1 -1
- data/lib/mencoro/models/get_me_stats200_response.rb +1 -1
- data/lib/mencoro/models/get_me_stats200_response_organizations.rb +1 -1
- data/lib/mencoro/models/get_me_stats200_response_projects.rb +2 -2
- data/lib/mencoro/models/get_membership_stats200_response.rb +1 -1
- data/lib/mencoro/models/get_mention_samples400_response.rb +1 -1
- data/lib/mencoro/models/get_mention_samples400_response_details_value_inner.rb +1 -1
- data/lib/mencoro/models/get_metric_glossary200_response.rb +1 -1
- data/lib/mencoro/models/get_metric_glossary200_response_metrics_inner.rb +1 -1
- data/lib/mencoro/models/get_organization_overview200_response.rb +1 -1
- data/lib/mencoro/models/get_organization_overview200_response_aggregate.rb +2 -2
- data/lib/mencoro/models/get_organization_overview200_response_projects_inner.rb +34 -3
- data/lib/mencoro/models/get_organization_stats200_response.rb +1 -1
- data/lib/mencoro/models/get_organization_stats200_response_invitations.rb +4 -7
- data/lib/mencoro/models/get_organization_stats200_response_members.rb +4 -7
- data/lib/mencoro/models/get_organization_stats200_response_projects.rb +2 -2
- data/lib/mencoro/models/get_share_of_voice_formula200_response.rb +1 -1
- data/lib/mencoro/models/get_tracking_coverage200_response.rb +1 -1
- data/lib/mencoro/models/get_tracking_coverage200_response_sample_inner.rb +1 -1
- data/lib/mencoro/models/invitation_resource.rb +64 -6
- data/lib/mencoro/models/keyword_listing_resource.rb +40 -14
- data/lib/mencoro/models/keyword_listing_resource_carried_positions.rb +187 -0
- data/lib/mencoro/models/keyword_listing_resource_carried_positions_serp.rb +192 -0
- data/lib/mencoro/models/keyword_listing_resource_mention_type_counts.rb +1 -1
- data/lib/mencoro/models/list_ai_responses200_response.rb +1 -1
- data/lib/mencoro/models/list_competitors200_response.rb +1 -1
- data/lib/mencoro/models/list_invitations200_response.rb +1 -1
- data/lib/mencoro/models/list_keyword_listings200_response.rb +1 -1
- data/lib/mencoro/models/list_members200_response.rb +1 -1
- data/lib/mencoro/models/list_organizations200_response.rb +1 -1
- data/lib/mencoro/models/list_projects200_response.rb +2 -2
- data/lib/mencoro/models/list_query_clusters200_response.rb +1 -1
- data/lib/mencoro/models/list_search_snapshots200_response.rb +1 -1
- data/lib/mencoro/models/list_shopping_snapshots200_response.rb +1 -1
- data/lib/mencoro/models/me_resource.rb +1 -1
- data/lib/mencoro/models/member_resource.rb +63 -5
- data/lib/mencoro/models/mention_match_resource.rb +432 -0
- data/lib/mencoro/models/mention_sample_response.rb +450 -0
- data/lib/mencoro/models/mention_type_counts.rb +268 -0
- data/lib/mencoro/models/operation_effect.rb +1 -1
- data/lib/mencoro/models/organization_resource.rb +1 -1
- data/lib/mencoro/models/per_competitor_sentiment.rb +304 -0
- data/lib/mencoro/models/per_engine_sentiment.rb +278 -0
- data/lib/mencoro/models/per_entity_metrics.rb +218 -0
- data/lib/mencoro/models/position_distribution_bucket.rb +190 -0
- data/lib/mencoro/models/preview_organization_operation200_response.rb +1 -1
- data/lib/mencoro/models/preview_organization_operation200_response_organization.rb +1 -1
- data/lib/mencoro/models/preview_organization_operation_request.rb +3 -3
- data/lib/mencoro/models/project_detail_resource.rb +1 -1
- data/lib/mencoro/models/project_detail_resource_competitors_inner.rb +1 -1
- data/lib/mencoro/models/project_mention_mix_response.rb +222 -0
- data/lib/mencoro/models/project_mention_samples_response.rb +192 -0
- data/lib/mencoro/models/project_rank_tracking_cluster_breakdown.rb +176 -0
- data/lib/mencoro/models/project_rank_tracking_stats.rb +718 -0
- data/lib/mencoro/models/project_rank_tracking_time_series.rb +176 -0
- data/lib/mencoro/models/project_resource.rb +1 -1
- data/lib/mencoro/models/project_sentiment_breakdown.rb +194 -0
- data/lib/mencoro/models/projected_monthly_checks_resource.rb +3 -3
- data/lib/mencoro/models/query_cluster_resource.rb +1 -1
- data/lib/mencoro/models/report_ai_response_request.rb +1 -1
- data/lib/mencoro/models/search_result_resource.rb +1 -1
- data/lib/mencoro/models/search_snapshot_resource.rb +1 -1
- data/lib/mencoro/models/search_tracked_queries200_response.rb +1 -1
- data/lib/mencoro/models/search_tracked_query_mention_matches200_response.rb +158 -0
- data/lib/mencoro/models/search_tracked_query_serp_matches200_response.rb +158 -0
- data/lib/mencoro/models/serp_match_resource.rb +314 -0
- data/lib/mencoro/models/set_member_project_access_request.rb +200 -0
- data/lib/mencoro/models/shopping_offer_resource.rb +1 -1
- data/lib/mencoro/models/shopping_snapshot_resource.rb +1 -1
- data/lib/mencoro/models/start_brand_discovery_job_request.rb +1 -1
- data/lib/mencoro/models/start_brand_name_suggestion_job_request.rb +1 -1
- data/lib/mencoro/models/start_clustering_job_request_data.rb +1 -1
- data/lib/mencoro/models/start_keyword_discovery_job_request.rb +1 -1
- data/lib/mencoro/models/start_prompt_discovery_job_request.rb +1 -1
- data/lib/mencoro/models/submitted_checks_resource.rb +1 -1
- data/lib/mencoro/models/subscription_resource.rb +3 -3
- data/lib/mencoro/models/time_series_point.rb +218 -0
- data/lib/mencoro/models/tracked_query_count_resource.rb +3 -3
- data/lib/mencoro/models/tracked_query_detail_resource.rb +3 -3
- data/lib/mencoro/models/tracked_query_mover_row.rb +492 -0
- data/lib/mencoro/models/tracked_query_movers_response.rb +202 -0
- data/lib/mencoro/models/tracked_query_rank_tracking_time_series.rb +176 -0
- data/lib/mencoro/models/tracked_query_resource.rb +3 -3
- data/lib/mencoro/models/tracked_query_usage_resource.rb +2 -2
- data/lib/mencoro/models/update_organization_request.rb +1 -1
- data/lib/mencoro/models/update_project_brand_profile_request.rb +1 -1
- data/lib/mencoro/models/update_project_request.rb +1 -1
- data/lib/mencoro/version.rb +2 -2
- data/lib/mencoro.rb +32 -1
- data/mencoro.gemspec +2 -2
- data/spec/models/async_job_resource_error_spec.rb +46 -0
- data/spec/models/cited_source_row_spec.rb +78 -0
- data/spec/models/cited_sources_response_spec.rb +42 -0
- data/spec/models/cluster_breakdown_row_spec.rb +228 -0
- data/spec/models/competitor_co_occurrence_response_spec.rb +36 -0
- data/spec/models/competitor_co_occurrence_row_spec.rb +90 -0
- data/spec/models/competitor_share_of_voice_spec.rb +42 -0
- data/spec/models/create_invitation_request_project_access_spec.rb +46 -0
- data/spec/models/keyword_listing_resource_carried_positions_serp_spec.rb +42 -0
- data/spec/models/keyword_listing_resource_carried_positions_spec.rb +54 -0
- data/spec/models/mention_match_resource_spec.rb +114 -0
- data/spec/models/mention_sample_response_spec.rb +114 -0
- data/spec/models/mention_type_counts_spec.rb +60 -0
- data/spec/models/per_competitor_sentiment_spec.rb +72 -0
- data/spec/models/per_engine_sentiment_spec.rb +66 -0
- data/spec/models/per_entity_metrics_spec.rb +78 -0
- data/spec/models/position_distribution_bucket_spec.rb +42 -0
- data/spec/models/project_mention_mix_response_spec.rb +48 -0
- data/spec/models/project_mention_samples_response_spec.rb +42 -0
- data/spec/models/project_rank_tracking_cluster_breakdown_spec.rb +42 -0
- data/spec/models/project_rank_tracking_stats_spec.rb +270 -0
- data/spec/models/project_rank_tracking_time_series_spec.rb +42 -0
- data/spec/models/project_sentiment_breakdown_spec.rb +42 -0
- data/spec/models/search_tracked_query_mention_matches200_response_spec.rb +42 -0
- data/spec/models/search_tracked_query_serp_matches200_response_spec.rb +42 -0
- data/spec/models/serp_match_resource_spec.rb +72 -0
- data/spec/models/set_member_project_access_request_spec.rb +46 -0
- data/spec/models/time_series_point_spec.rb +48 -0
- data/spec/models/tracked_query_mover_row_spec.rb +156 -0
- data/spec/models/tracked_query_movers_response_spec.rb +48 -0
- data/spec/models/tracked_query_rank_tracking_time_series_spec.rb +42 -0
- data/spec/spec_helper.rb +1 -1
- metadata +235 -108
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Mencoro API
|
|
3
|
+
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
Contact: support@mencoro.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.24.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module Mencoro
|
|
17
|
+
class PerEntityMetrics < ApiModelBase
|
|
18
|
+
attr_accessor :serp
|
|
19
|
+
|
|
20
|
+
attr_accessor :shopping
|
|
21
|
+
|
|
22
|
+
attr_accessor :mention
|
|
23
|
+
|
|
24
|
+
attr_accessor :link
|
|
25
|
+
|
|
26
|
+
attr_accessor :positivity
|
|
27
|
+
|
|
28
|
+
attr_accessor :share_of_voice
|
|
29
|
+
|
|
30
|
+
attr_accessor :mention_rate
|
|
31
|
+
|
|
32
|
+
attr_accessor :serp_rate
|
|
33
|
+
|
|
34
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
35
|
+
def self.attribute_map
|
|
36
|
+
{
|
|
37
|
+
:'serp' => :'serp',
|
|
38
|
+
:'shopping' => :'shopping',
|
|
39
|
+
:'mention' => :'mention',
|
|
40
|
+
:'link' => :'link',
|
|
41
|
+
:'positivity' => :'positivity',
|
|
42
|
+
:'share_of_voice' => :'shareOfVoice',
|
|
43
|
+
:'mention_rate' => :'mentionRate',
|
|
44
|
+
:'serp_rate' => :'serpRate'
|
|
45
|
+
}
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Returns attribute mapping this model knows about
|
|
49
|
+
def self.acceptable_attribute_map
|
|
50
|
+
attribute_map
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Returns all the JSON keys this model knows about
|
|
54
|
+
def self.acceptable_attributes
|
|
55
|
+
acceptable_attribute_map.values
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
# Attribute type mapping.
|
|
59
|
+
def self.openapi_types
|
|
60
|
+
{
|
|
61
|
+
:'serp' => :'Float',
|
|
62
|
+
:'shopping' => :'Float',
|
|
63
|
+
:'mention' => :'Float',
|
|
64
|
+
:'link' => :'Float',
|
|
65
|
+
:'positivity' => :'Integer',
|
|
66
|
+
:'share_of_voice' => :'Float',
|
|
67
|
+
:'mention_rate' => :'Integer',
|
|
68
|
+
:'serp_rate' => :'Integer'
|
|
69
|
+
}
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
# List of attributes with nullable: true
|
|
73
|
+
def self.openapi_nullable
|
|
74
|
+
Set.new([
|
|
75
|
+
:'serp',
|
|
76
|
+
:'shopping',
|
|
77
|
+
:'mention',
|
|
78
|
+
:'link',
|
|
79
|
+
:'positivity',
|
|
80
|
+
:'share_of_voice',
|
|
81
|
+
:'mention_rate',
|
|
82
|
+
:'serp_rate'
|
|
83
|
+
])
|
|
84
|
+
end
|
|
85
|
+
|
|
86
|
+
# Initializes the object
|
|
87
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
88
|
+
def initialize(attributes = {})
|
|
89
|
+
if (!attributes.is_a?(Hash))
|
|
90
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Mencoro::PerEntityMetrics` initialize method"
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
94
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
95
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
96
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
97
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Mencoro::PerEntityMetrics`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
98
|
+
end
|
|
99
|
+
h[k.to_sym] = v
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
if attributes.key?(:'serp')
|
|
103
|
+
self.serp = attributes[:'serp']
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
if attributes.key?(:'shopping')
|
|
107
|
+
self.shopping = attributes[:'shopping']
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
if attributes.key?(:'mention')
|
|
111
|
+
self.mention = attributes[:'mention']
|
|
112
|
+
end
|
|
113
|
+
|
|
114
|
+
if attributes.key?(:'link')
|
|
115
|
+
self.link = attributes[:'link']
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
if attributes.key?(:'positivity')
|
|
119
|
+
self.positivity = attributes[:'positivity']
|
|
120
|
+
end
|
|
121
|
+
|
|
122
|
+
if attributes.key?(:'share_of_voice')
|
|
123
|
+
self.share_of_voice = attributes[:'share_of_voice']
|
|
124
|
+
end
|
|
125
|
+
|
|
126
|
+
if attributes.key?(:'mention_rate')
|
|
127
|
+
self.mention_rate = attributes[:'mention_rate']
|
|
128
|
+
end
|
|
129
|
+
|
|
130
|
+
if attributes.key?(:'serp_rate')
|
|
131
|
+
self.serp_rate = attributes[:'serp_rate']
|
|
132
|
+
end
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
136
|
+
# @return Array for valid properties with the reasons
|
|
137
|
+
def list_invalid_properties
|
|
138
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
139
|
+
invalid_properties = Array.new
|
|
140
|
+
invalid_properties
|
|
141
|
+
end
|
|
142
|
+
|
|
143
|
+
# Check to see if the all the properties in the model are valid
|
|
144
|
+
# @return true if the model is valid
|
|
145
|
+
def valid?
|
|
146
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
147
|
+
true
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
# Checks equality by comparing each attribute.
|
|
151
|
+
# @param [Object] Object to be compared
|
|
152
|
+
def ==(o)
|
|
153
|
+
return true if self.equal?(o)
|
|
154
|
+
self.class == o.class &&
|
|
155
|
+
serp == o.serp &&
|
|
156
|
+
shopping == o.shopping &&
|
|
157
|
+
mention == o.mention &&
|
|
158
|
+
link == o.link &&
|
|
159
|
+
positivity == o.positivity &&
|
|
160
|
+
share_of_voice == o.share_of_voice &&
|
|
161
|
+
mention_rate == o.mention_rate &&
|
|
162
|
+
serp_rate == o.serp_rate
|
|
163
|
+
end
|
|
164
|
+
|
|
165
|
+
# @see the `==` method
|
|
166
|
+
# @param [Object] Object to be compared
|
|
167
|
+
def eql?(o)
|
|
168
|
+
self == o
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
# Calculates hash code according to all attributes.
|
|
172
|
+
# @return [Integer] Hash code
|
|
173
|
+
def hash
|
|
174
|
+
[serp, shopping, mention, link, positivity, share_of_voice, mention_rate, serp_rate].hash
|
|
175
|
+
end
|
|
176
|
+
|
|
177
|
+
# Builds the object from hash
|
|
178
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
179
|
+
# @return [Object] Returns the model itself
|
|
180
|
+
def self.build_from_hash(attributes)
|
|
181
|
+
return nil unless attributes.is_a?(Hash)
|
|
182
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
183
|
+
transformed_hash = {}
|
|
184
|
+
openapi_types.each_pair do |key, type|
|
|
185
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
186
|
+
transformed_hash["#{key}"] = nil
|
|
187
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
188
|
+
# check to ensure the input is an array given that the attribute
|
|
189
|
+
# is documented as an array but the input is not
|
|
190
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
191
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
192
|
+
end
|
|
193
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
194
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
195
|
+
end
|
|
196
|
+
end
|
|
197
|
+
new(transformed_hash)
|
|
198
|
+
end
|
|
199
|
+
|
|
200
|
+
# Returns the object in the form of hash
|
|
201
|
+
# @return [Hash] Returns the object in the form of hash
|
|
202
|
+
def to_hash
|
|
203
|
+
hash = {}
|
|
204
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
205
|
+
value = self.send(attr)
|
|
206
|
+
if value.nil?
|
|
207
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
208
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
209
|
+
end
|
|
210
|
+
|
|
211
|
+
hash[param] = _to_hash(value)
|
|
212
|
+
end
|
|
213
|
+
hash
|
|
214
|
+
end
|
|
215
|
+
|
|
216
|
+
end
|
|
217
|
+
|
|
218
|
+
end
|
|
@@ -0,0 +1,190 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Mencoro API
|
|
3
|
+
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
Contact: support@mencoro.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.24.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module Mencoro
|
|
17
|
+
class PositionDistributionBucket < ApiModelBase
|
|
18
|
+
attr_accessor :bucket
|
|
19
|
+
|
|
20
|
+
attr_accessor :count
|
|
21
|
+
|
|
22
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
23
|
+
def self.attribute_map
|
|
24
|
+
{
|
|
25
|
+
:'bucket' => :'bucket',
|
|
26
|
+
:'count' => :'count'
|
|
27
|
+
}
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
# Returns attribute mapping this model knows about
|
|
31
|
+
def self.acceptable_attribute_map
|
|
32
|
+
attribute_map
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# Returns all the JSON keys this model knows about
|
|
36
|
+
def self.acceptable_attributes
|
|
37
|
+
acceptable_attribute_map.values
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
# Attribute type mapping.
|
|
41
|
+
def self.openapi_types
|
|
42
|
+
{
|
|
43
|
+
:'bucket' => :'String',
|
|
44
|
+
:'count' => :'Integer'
|
|
45
|
+
}
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# List of attributes with nullable: true
|
|
49
|
+
def self.openapi_nullable
|
|
50
|
+
Set.new([
|
|
51
|
+
])
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
# Initializes the object
|
|
55
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
56
|
+
def initialize(attributes = {})
|
|
57
|
+
if (!attributes.is_a?(Hash))
|
|
58
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Mencoro::PositionDistributionBucket` initialize method"
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
62
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
63
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
64
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
65
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Mencoro::PositionDistributionBucket`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
66
|
+
end
|
|
67
|
+
h[k.to_sym] = v
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
if attributes.key?(:'bucket')
|
|
71
|
+
self.bucket = attributes[:'bucket']
|
|
72
|
+
else
|
|
73
|
+
self.bucket = nil
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
if attributes.key?(:'count')
|
|
77
|
+
self.count = attributes[:'count']
|
|
78
|
+
else
|
|
79
|
+
self.count = nil
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
84
|
+
# @return Array for valid properties with the reasons
|
|
85
|
+
def list_invalid_properties
|
|
86
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
87
|
+
invalid_properties = Array.new
|
|
88
|
+
if @bucket.nil?
|
|
89
|
+
invalid_properties.push('invalid value for "bucket", bucket cannot be nil.')
|
|
90
|
+
end
|
|
91
|
+
|
|
92
|
+
if @count.nil?
|
|
93
|
+
invalid_properties.push('invalid value for "count", count cannot be nil.')
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
invalid_properties
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
# Check to see if the all the properties in the model are valid
|
|
100
|
+
# @return true if the model is valid
|
|
101
|
+
def valid?
|
|
102
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
103
|
+
return false if @bucket.nil?
|
|
104
|
+
return false if @count.nil?
|
|
105
|
+
true
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
# Custom attribute writer method with validation
|
|
109
|
+
# @param [Object] bucket Value to be assigned
|
|
110
|
+
def bucket=(bucket)
|
|
111
|
+
if bucket.nil?
|
|
112
|
+
fail ArgumentError, 'bucket cannot be nil'
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
@bucket = bucket
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
# Custom attribute writer method with validation
|
|
119
|
+
# @param [Object] count Value to be assigned
|
|
120
|
+
def count=(count)
|
|
121
|
+
if count.nil?
|
|
122
|
+
fail ArgumentError, 'count cannot be nil'
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
@count = count
|
|
126
|
+
end
|
|
127
|
+
|
|
128
|
+
# Checks equality by comparing each attribute.
|
|
129
|
+
# @param [Object] Object to be compared
|
|
130
|
+
def ==(o)
|
|
131
|
+
return true if self.equal?(o)
|
|
132
|
+
self.class == o.class &&
|
|
133
|
+
bucket == o.bucket &&
|
|
134
|
+
count == o.count
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
# @see the `==` method
|
|
138
|
+
# @param [Object] Object to be compared
|
|
139
|
+
def eql?(o)
|
|
140
|
+
self == o
|
|
141
|
+
end
|
|
142
|
+
|
|
143
|
+
# Calculates hash code according to all attributes.
|
|
144
|
+
# @return [Integer] Hash code
|
|
145
|
+
def hash
|
|
146
|
+
[bucket, count].hash
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
# Builds the object from hash
|
|
150
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
151
|
+
# @return [Object] Returns the model itself
|
|
152
|
+
def self.build_from_hash(attributes)
|
|
153
|
+
return nil unless attributes.is_a?(Hash)
|
|
154
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
155
|
+
transformed_hash = {}
|
|
156
|
+
openapi_types.each_pair do |key, type|
|
|
157
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
158
|
+
transformed_hash["#{key}"] = nil
|
|
159
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
160
|
+
# check to ensure the input is an array given that the attribute
|
|
161
|
+
# is documented as an array but the input is not
|
|
162
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
163
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
164
|
+
end
|
|
165
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
166
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
167
|
+
end
|
|
168
|
+
end
|
|
169
|
+
new(transformed_hash)
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
# Returns the object in the form of hash
|
|
173
|
+
# @return [Hash] Returns the object in the form of hash
|
|
174
|
+
def to_hash
|
|
175
|
+
hash = {}
|
|
176
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
177
|
+
value = self.send(attr)
|
|
178
|
+
if value.nil?
|
|
179
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
180
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
181
|
+
end
|
|
182
|
+
|
|
183
|
+
hash[param] = _to_hash(value)
|
|
184
|
+
end
|
|
185
|
+
hash
|
|
186
|
+
end
|
|
187
|
+
|
|
188
|
+
end
|
|
189
|
+
|
|
190
|
+
end
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#Mencoro API
|
|
3
3
|
|
|
4
|
-
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`.
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
5
|
|
|
6
6
|
The version of the OpenAPI document: 1.0.0
|
|
7
7
|
Contact: support@mencoro.com
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#Mencoro API
|
|
3
3
|
|
|
4
|
-
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`.
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
5
|
|
|
6
6
|
The version of the OpenAPI document: 1.0.0
|
|
7
7
|
Contact: support@mencoro.com
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#Mencoro API
|
|
3
3
|
|
|
4
|
-
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`.
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
5
|
|
|
6
6
|
The version of the OpenAPI document: 1.0.0
|
|
7
7
|
Contact: support@mencoro.com
|
|
@@ -131,7 +131,7 @@ module Mencoro
|
|
|
131
131
|
# @return true if the model is valid
|
|
132
132
|
def valid?
|
|
133
133
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
134
|
-
action_validator = EnumAttributeValidator.new('String', ["createOrganization", "updateOrganization", "archiveOrganization", "restoreOrganization", "changeMemberRole", "suspendMember", "reactivateMember", "createInvitation", "cancelInvitation"])
|
|
134
|
+
action_validator = EnumAttributeValidator.new('String', ["createOrganization", "updateOrganization", "archiveOrganization", "restoreOrganization", "changeMemberRole", "suspendMember", "reactivateMember", "setMemberProjectAccess", "createInvitation", "cancelInvitation"])
|
|
135
135
|
return false unless action_validator.valid?(@action)
|
|
136
136
|
true
|
|
137
137
|
end
|
|
@@ -139,7 +139,7 @@ module Mencoro
|
|
|
139
139
|
# Custom attribute writer method checking allowed values (enum).
|
|
140
140
|
# @param [Object] action Object to be assigned
|
|
141
141
|
def action=(action)
|
|
142
|
-
validator = EnumAttributeValidator.new('String', ["createOrganization", "updateOrganization", "archiveOrganization", "restoreOrganization", "changeMemberRole", "suspendMember", "reactivateMember", "createInvitation", "cancelInvitation"])
|
|
142
|
+
validator = EnumAttributeValidator.new('String', ["createOrganization", "updateOrganization", "archiveOrganization", "restoreOrganization", "changeMemberRole", "suspendMember", "reactivateMember", "setMemberProjectAccess", "createInvitation", "cancelInvitation"])
|
|
143
143
|
unless validator.valid?(action)
|
|
144
144
|
fail ArgumentError, "invalid value for \"action\", must be one of #{validator.allowable_values}."
|
|
145
145
|
end
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#Mencoro API
|
|
3
3
|
|
|
4
|
-
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`.
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
5
|
|
|
6
6
|
The version of the OpenAPI document: 1.0.0
|
|
7
7
|
Contact: support@mencoro.com
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#Mencoro API
|
|
3
3
|
|
|
4
|
-
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`.
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
5
|
|
|
6
6
|
The version of the OpenAPI document: 1.0.0
|
|
7
7
|
Contact: support@mencoro.com
|
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Mencoro API
|
|
3
|
+
|
|
4
|
+
#Public API for Mencoro customers. Authenticate with an API key: `Authorization: Bearer mencoro_sk_...`. Every write operation requires an `Idempotency-Key` header: a retry carrying the same key and body within 30 days is answered from the stored result without running again; after 30 days the key is forgotten and a retry runs as a new operation.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
Contact: support@mencoro.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.24.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module Mencoro
|
|
17
|
+
class ProjectMentionMixResponse < ApiModelBase
|
|
18
|
+
attr_accessor :by_type
|
|
19
|
+
|
|
20
|
+
attr_accessor :by_tone
|
|
21
|
+
|
|
22
|
+
attr_accessor :by_qualifier
|
|
23
|
+
|
|
24
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
25
|
+
def self.attribute_map
|
|
26
|
+
{
|
|
27
|
+
:'by_type' => :'byType',
|
|
28
|
+
:'by_tone' => :'byTone',
|
|
29
|
+
:'by_qualifier' => :'byQualifier'
|
|
30
|
+
}
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
# Returns attribute mapping this model knows about
|
|
34
|
+
def self.acceptable_attribute_map
|
|
35
|
+
attribute_map
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
# Returns all the JSON keys this model knows about
|
|
39
|
+
def self.acceptable_attributes
|
|
40
|
+
acceptable_attribute_map.values
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
# Attribute type mapping.
|
|
44
|
+
def self.openapi_types
|
|
45
|
+
{
|
|
46
|
+
:'by_type' => :'Hash<String, Integer>',
|
|
47
|
+
:'by_tone' => :'Hash<String, Integer>',
|
|
48
|
+
:'by_qualifier' => :'Hash<String, Integer>'
|
|
49
|
+
}
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
# List of attributes with nullable: true
|
|
53
|
+
def self.openapi_nullable
|
|
54
|
+
Set.new([
|
|
55
|
+
])
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
# Initializes the object
|
|
59
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
60
|
+
def initialize(attributes = {})
|
|
61
|
+
if (!attributes.is_a?(Hash))
|
|
62
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Mencoro::ProjectMentionMixResponse` initialize method"
|
|
63
|
+
end
|
|
64
|
+
|
|
65
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
66
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
67
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
68
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
69
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Mencoro::ProjectMentionMixResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
70
|
+
end
|
|
71
|
+
h[k.to_sym] = v
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
if attributes.key?(:'by_type')
|
|
75
|
+
if (value = attributes[:'by_type']).is_a?(Hash)
|
|
76
|
+
self.by_type = value
|
|
77
|
+
end
|
|
78
|
+
else
|
|
79
|
+
self.by_type = nil
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
if attributes.key?(:'by_tone')
|
|
83
|
+
if (value = attributes[:'by_tone']).is_a?(Hash)
|
|
84
|
+
self.by_tone = value
|
|
85
|
+
end
|
|
86
|
+
else
|
|
87
|
+
self.by_tone = nil
|
|
88
|
+
end
|
|
89
|
+
|
|
90
|
+
if attributes.key?(:'by_qualifier')
|
|
91
|
+
if (value = attributes[:'by_qualifier']).is_a?(Hash)
|
|
92
|
+
self.by_qualifier = value
|
|
93
|
+
end
|
|
94
|
+
else
|
|
95
|
+
self.by_qualifier = nil
|
|
96
|
+
end
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
100
|
+
# @return Array for valid properties with the reasons
|
|
101
|
+
def list_invalid_properties
|
|
102
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
103
|
+
invalid_properties = Array.new
|
|
104
|
+
if @by_type.nil?
|
|
105
|
+
invalid_properties.push('invalid value for "by_type", by_type cannot be nil.')
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
if @by_tone.nil?
|
|
109
|
+
invalid_properties.push('invalid value for "by_tone", by_tone cannot be nil.')
|
|
110
|
+
end
|
|
111
|
+
|
|
112
|
+
if @by_qualifier.nil?
|
|
113
|
+
invalid_properties.push('invalid value for "by_qualifier", by_qualifier cannot be nil.')
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
invalid_properties
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
# Check to see if the all the properties in the model are valid
|
|
120
|
+
# @return true if the model is valid
|
|
121
|
+
def valid?
|
|
122
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
123
|
+
return false if @by_type.nil?
|
|
124
|
+
return false if @by_tone.nil?
|
|
125
|
+
return false if @by_qualifier.nil?
|
|
126
|
+
true
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
# Custom attribute writer method with validation
|
|
130
|
+
# @param [Object] by_type Value to be assigned
|
|
131
|
+
def by_type=(by_type)
|
|
132
|
+
if by_type.nil?
|
|
133
|
+
fail ArgumentError, 'by_type cannot be nil'
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
@by_type = by_type
|
|
137
|
+
end
|
|
138
|
+
|
|
139
|
+
# Custom attribute writer method with validation
|
|
140
|
+
# @param [Object] by_tone Value to be assigned
|
|
141
|
+
def by_tone=(by_tone)
|
|
142
|
+
if by_tone.nil?
|
|
143
|
+
fail ArgumentError, 'by_tone cannot be nil'
|
|
144
|
+
end
|
|
145
|
+
|
|
146
|
+
@by_tone = by_tone
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
# Custom attribute writer method with validation
|
|
150
|
+
# @param [Object] by_qualifier Value to be assigned
|
|
151
|
+
def by_qualifier=(by_qualifier)
|
|
152
|
+
if by_qualifier.nil?
|
|
153
|
+
fail ArgumentError, 'by_qualifier cannot be nil'
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
@by_qualifier = by_qualifier
|
|
157
|
+
end
|
|
158
|
+
|
|
159
|
+
# Checks equality by comparing each attribute.
|
|
160
|
+
# @param [Object] Object to be compared
|
|
161
|
+
def ==(o)
|
|
162
|
+
return true if self.equal?(o)
|
|
163
|
+
self.class == o.class &&
|
|
164
|
+
by_type == o.by_type &&
|
|
165
|
+
by_tone == o.by_tone &&
|
|
166
|
+
by_qualifier == o.by_qualifier
|
|
167
|
+
end
|
|
168
|
+
|
|
169
|
+
# @see the `==` method
|
|
170
|
+
# @param [Object] Object to be compared
|
|
171
|
+
def eql?(o)
|
|
172
|
+
self == o
|
|
173
|
+
end
|
|
174
|
+
|
|
175
|
+
# Calculates hash code according to all attributes.
|
|
176
|
+
# @return [Integer] Hash code
|
|
177
|
+
def hash
|
|
178
|
+
[by_type, by_tone, by_qualifier].hash
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
# Builds the object from hash
|
|
182
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
183
|
+
# @return [Object] Returns the model itself
|
|
184
|
+
def self.build_from_hash(attributes)
|
|
185
|
+
return nil unless attributes.is_a?(Hash)
|
|
186
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
187
|
+
transformed_hash = {}
|
|
188
|
+
openapi_types.each_pair do |key, type|
|
|
189
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
190
|
+
transformed_hash["#{key}"] = nil
|
|
191
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
192
|
+
# check to ensure the input is an array given that the attribute
|
|
193
|
+
# is documented as an array but the input is not
|
|
194
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
195
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
196
|
+
end
|
|
197
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
198
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
199
|
+
end
|
|
200
|
+
end
|
|
201
|
+
new(transformed_hash)
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
# Returns the object in the form of hash
|
|
205
|
+
# @return [Hash] Returns the object in the form of hash
|
|
206
|
+
def to_hash
|
|
207
|
+
hash = {}
|
|
208
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
209
|
+
value = self.send(attr)
|
|
210
|
+
if value.nil?
|
|
211
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
212
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
213
|
+
end
|
|
214
|
+
|
|
215
|
+
hash[param] = _to_hash(value)
|
|
216
|
+
end
|
|
217
|
+
hash
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
end
|
|
221
|
+
|
|
222
|
+
end
|