File: representations.rb

package info (click to toggle)
ruby-google-api-client 0.33.0-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 56,648 kB
  • sloc: ruby: 475,555; makefile: 4
file content (210 lines) | stat: -rw-r--r-- 8,392 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

require 'date'
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'

module Google
  module Apis
    module CommentanalyzerV1alpha1
      
      class AnalyzeCommentRequest
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class AnalyzeCommentResponse
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class ArticleAndParentComment
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class AttributeParameters
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class AttributeScores
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class Context
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class Score
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class SpanScore
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class SuggestCommentScoreRequest
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class SuggestCommentScoreResponse
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class TextEntry
        class Representation < Google::Apis::Core::JsonRepresentation; end
      
        include Google::Apis::Core::JsonObjectSupport
      end
      
      class AnalyzeCommentRequest
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :client_token, as: 'clientToken'
          property :comment, as: 'comment', class: Google::Apis::CommentanalyzerV1alpha1::TextEntry, decorator: Google::Apis::CommentanalyzerV1alpha1::TextEntry::Representation
      
          property :community_id, as: 'communityId'
          property :context, as: 'context', class: Google::Apis::CommentanalyzerV1alpha1::Context, decorator: Google::Apis::CommentanalyzerV1alpha1::Context::Representation
      
          property :do_not_store, as: 'doNotStore'
          collection :languages, as: 'languages'
          hash :requested_attributes, as: 'requestedAttributes', class: Google::Apis::CommentanalyzerV1alpha1::AttributeParameters, decorator: Google::Apis::CommentanalyzerV1alpha1::AttributeParameters::Representation
      
          property :session_id, as: 'sessionId'
          property :span_annotations, as: 'spanAnnotations'
        end
      end
      
      class AnalyzeCommentResponse
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          hash :attribute_scores, as: 'attributeScores', class: Google::Apis::CommentanalyzerV1alpha1::AttributeScores, decorator: Google::Apis::CommentanalyzerV1alpha1::AttributeScores::Representation
      
          property :client_token, as: 'clientToken'
          collection :detected_languages, as: 'detectedLanguages'
          collection :languages, as: 'languages'
        end
      end
      
      class ArticleAndParentComment
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :article, as: 'article', class: Google::Apis::CommentanalyzerV1alpha1::TextEntry, decorator: Google::Apis::CommentanalyzerV1alpha1::TextEntry::Representation
      
          property :parent_comment, as: 'parentComment', class: Google::Apis::CommentanalyzerV1alpha1::TextEntry, decorator: Google::Apis::CommentanalyzerV1alpha1::TextEntry::Representation
      
        end
      end
      
      class AttributeParameters
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :score_threshold, as: 'scoreThreshold'
          property :score_type, as: 'scoreType'
        end
      end
      
      class AttributeScores
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          collection :span_scores, as: 'spanScores', class: Google::Apis::CommentanalyzerV1alpha1::SpanScore, decorator: Google::Apis::CommentanalyzerV1alpha1::SpanScore::Representation
      
          property :summary_score, as: 'summaryScore', class: Google::Apis::CommentanalyzerV1alpha1::Score, decorator: Google::Apis::CommentanalyzerV1alpha1::Score::Representation
      
        end
      end
      
      class Context
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :article_and_parent_comment, as: 'articleAndParentComment', class: Google::Apis::CommentanalyzerV1alpha1::ArticleAndParentComment, decorator: Google::Apis::CommentanalyzerV1alpha1::ArticleAndParentComment::Representation
      
          collection :entries, as: 'entries', class: Google::Apis::CommentanalyzerV1alpha1::TextEntry, decorator: Google::Apis::CommentanalyzerV1alpha1::TextEntry::Representation
      
        end
      end
      
      class Score
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :type, as: 'type'
          property :value, as: 'value'
        end
      end
      
      class SpanScore
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :begin, as: 'begin'
          property :end, as: 'end'
          property :score, as: 'score', class: Google::Apis::CommentanalyzerV1alpha1::Score, decorator: Google::Apis::CommentanalyzerV1alpha1::Score::Representation
      
        end
      end
      
      class SuggestCommentScoreRequest
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          hash :attribute_scores, as: 'attributeScores', class: Google::Apis::CommentanalyzerV1alpha1::AttributeScores, decorator: Google::Apis::CommentanalyzerV1alpha1::AttributeScores::Representation
      
          property :client_token, as: 'clientToken'
          property :comment, as: 'comment', class: Google::Apis::CommentanalyzerV1alpha1::TextEntry, decorator: Google::Apis::CommentanalyzerV1alpha1::TextEntry::Representation
      
          property :community_id, as: 'communityId'
          property :context, as: 'context', class: Google::Apis::CommentanalyzerV1alpha1::Context, decorator: Google::Apis::CommentanalyzerV1alpha1::Context::Representation
      
          collection :languages, as: 'languages'
          property :session_id, as: 'sessionId'
        end
      end
      
      class SuggestCommentScoreResponse
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :client_token, as: 'clientToken'
          collection :detected_languages, as: 'detectedLanguages'
          collection :requested_languages, as: 'requestedLanguages'
        end
      end
      
      class TextEntry
        # @private
        class Representation < Google::Apis::Core::JsonRepresentation
          property :text, as: 'text'
          property :type, as: 'type'
        end
      end
    end
  end
end