google-apis-documentai_v1beta2 0.7.0 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 705924780649685c53473ec217eb0c74a1c82047c2832b253dc79eba77e2ad30
|
4
|
+
data.tar.gz: 66cd77361e2f8c3ce89bf3e352073542b069883b18c2e64ca8fd4b2536faa12d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9366f71f3600d5099d35be5cc03493e547fef99e1146bebd04421e3f7db18b1193b889c84cb4ad03d108169998b36e2ee276cb49d89f05acf23c39940d54f725
|
7
|
+
data.tar.gz: 691af8764b3848887e1a97041cba2d823b0ca9b5bfb4988f32fe2547204b82e4f5f3012e277129bac655cdc7b3a920feba08038f3585e678f2a4d7c7c7e747e3
|
data/CHANGELOG.md
CHANGED
@@ -31,7 +31,7 @@ module Google
|
|
31
31
|
# This is NOT the gem version.
|
32
32
|
VERSION = 'V1beta2'
|
33
33
|
|
34
|
-
#
|
34
|
+
# See, edit, configure, and delete your Google Cloud Platform data
|
35
35
|
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
|
36
36
|
end
|
37
37
|
end
|
@@ -271,25 +271,6 @@ module Google
|
|
271
271
|
end
|
272
272
|
end
|
273
273
|
|
274
|
-
# The long running operation metadata for SampleDataset.
|
275
|
-
class GoogleCloudDocumentaiUiv1beta3SampleDatasetMetadata
|
276
|
-
include Google::Apis::Core::Hashable
|
277
|
-
|
278
|
-
# The common metadata for long running operations.
|
279
|
-
# Corresponds to the JSON property `commonMetadata`
|
280
|
-
# @return [Google::Apis::DocumentaiV1beta2::GoogleCloudDocumentaiUiv1beta3CommonOperationMetadata]
|
281
|
-
attr_accessor :common_metadata
|
282
|
-
|
283
|
-
def initialize(**args)
|
284
|
-
update!(**args)
|
285
|
-
end
|
286
|
-
|
287
|
-
# Update properties of this object
|
288
|
-
def update!(**args)
|
289
|
-
@common_metadata = args[:common_metadata] if args.key?(:common_metadata)
|
290
|
-
end
|
291
|
-
end
|
292
|
-
|
293
274
|
# The long running operation metadata for set default processor version method.
|
294
275
|
class GoogleCloudDocumentaiUiv1beta3SetDefaultProcessorVersionMetadata
|
295
276
|
include Google::Apis::Core::Hashable
|
@@ -1876,98 +1857,98 @@ module Google
|
|
1876
1857
|
|
1877
1858
|
# Represents a color in the RGBA color space. This representation is designed
|
1878
1859
|
# for simplicity of conversion to/from color representations in various
|
1879
|
-
# languages over compactness
|
1880
|
-
# be trivially provided to the constructor of
|
1881
|
-
# also be trivially provided to UIColor's
|
1860
|
+
# languages over compactness. For example, the fields of this representation can
|
1861
|
+
# be trivially provided to the constructor of `java.awt.Color` in Java; it can
|
1862
|
+
# also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha`
|
1882
1863
|
# method in iOS; and, with just a little work, it can be easily formatted into a
|
1883
|
-
# CSS
|
1864
|
+
# CSS `rgba()` string in JavaScript. This reference page doesn't carry
|
1884
1865
|
# information about the absolute color space that should be used to interpret
|
1885
1866
|
# the RGB value (e.g. sRGB, Adobe RGB, DCI-P3, BT.2020, etc.). By default,
|
1886
|
-
# applications
|
1887
|
-
#
|
1888
|
-
#
|
1889
|
-
#
|
1890
|
-
#
|
1891
|
-
# protocolor.
|
1892
|
-
#
|
1893
|
-
#
|
1894
|
-
# float
|
1895
|
-
# float
|
1896
|
-
#
|
1897
|
-
#
|
1898
|
-
#
|
1899
|
-
#
|
1900
|
-
#
|
1901
|
-
#
|
1902
|
-
#
|
1903
|
-
#
|
1904
|
-
#
|
1905
|
-
#
|
1906
|
-
#
|
1907
|
-
#
|
1908
|
-
#
|
1909
|
-
#
|
1910
|
-
#
|
1867
|
+
# applications should assume the sRGB color space. When color equality needs to
|
1868
|
+
# be decided, implementations, unless documented otherwise, treat two colors as
|
1869
|
+
# equal if all their red, green, blue, and alpha values each differ by at most
|
1870
|
+
# 1e-5. Example (Java): import com.google.type.Color; // ... public static java.
|
1871
|
+
# awt.Color fromProto(Color protocolor) ` float alpha = protocolor.hasAlpha() ?
|
1872
|
+
# protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.
|
1873
|
+
# getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); ` public static
|
1874
|
+
# Color toProto(java.awt.Color color) ` float red = (float) color.getRed();
|
1875
|
+
# float green = (float) color.getGreen(); float blue = (float) color.getBlue();
|
1876
|
+
# float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .
|
1877
|
+
# setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue /
|
1878
|
+
# denominator); int alpha = color.getAlpha(); if (alpha != 255) ` result.
|
1879
|
+
# setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .
|
1880
|
+
# build()); ` return resultBuilder.build(); ` // ... Example (iOS / Obj-C): // ..
|
1881
|
+
# . static UIColor* fromProto(Color* protocolor) ` float red = [protocolor red];
|
1882
|
+
# float green = [protocolor green]; float blue = [protocolor blue]; FloatValue*
|
1883
|
+
# alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper !=
|
1884
|
+
# nil) ` alpha = [alpha_wrapper value]; ` return [UIColor colorWithRed:red green:
|
1885
|
+
# green blue:blue alpha:alpha]; ` static Color* toProto(UIColor* color) `
|
1886
|
+
# CGFloat red, green, blue, alpha; if (![color getRed:&red green:&green blue:&
|
1887
|
+
# blue alpha:&alpha]) ` return nil; ` Color* result = [[Color alloc] init]; [
|
1888
|
+
# result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha <
|
1889
|
+
# = 0.9999) ` [result setAlpha:floatWrapperWithValue(alpha)]; ` [result
|
1890
|
+
# autorelease]; return result; ` // ... Example (JavaScript): // ... var
|
1891
|
+
# protoToCssColor = function(rgb_color) ` var redFrac = rgb_color.red || 0.0;
|
1911
1892
|
# var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0;
|
1912
1893
|
# var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255);
|
1913
1894
|
# var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) ` return
|
1914
|
-
#
|
1895
|
+
# rgbToCssColor(red, green, blue); ` var alphaFrac = rgb_color.alpha.value || 0.
|
1915
1896
|
# 0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',
|
1916
|
-
# ', alphaFrac, ')'].join(''); `; var
|
1917
|
-
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var
|
1918
|
-
#
|
1919
|
-
#
|
1920
|
-
#
|
1921
|
-
#
|
1897
|
+
# ', alphaFrac, ')'].join(''); `; var rgbToCssColor = function(red, green, blue)
|
1898
|
+
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var hexString
|
1899
|
+
# = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var
|
1900
|
+
# resultBuilder = ['#']; for (var i = 0; i < missingZeros; i++) ` resultBuilder.
|
1901
|
+
# push('0'); ` resultBuilder.push(hexString); return resultBuilder.join(''); `; /
|
1902
|
+
# / ...
|
1922
1903
|
# Corresponds to the JSON property `backgroundColor`
|
1923
1904
|
# @return [Google::Apis::DocumentaiV1beta2::GoogleTypeColor]
|
1924
1905
|
attr_accessor :background_color
|
1925
1906
|
|
1926
1907
|
# Represents a color in the RGBA color space. This representation is designed
|
1927
1908
|
# for simplicity of conversion to/from color representations in various
|
1928
|
-
# languages over compactness
|
1929
|
-
# be trivially provided to the constructor of
|
1930
|
-
# also be trivially provided to UIColor's
|
1909
|
+
# languages over compactness. For example, the fields of this representation can
|
1910
|
+
# be trivially provided to the constructor of `java.awt.Color` in Java; it can
|
1911
|
+
# also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha`
|
1931
1912
|
# method in iOS; and, with just a little work, it can be easily formatted into a
|
1932
|
-
# CSS
|
1913
|
+
# CSS `rgba()` string in JavaScript. This reference page doesn't carry
|
1933
1914
|
# information about the absolute color space that should be used to interpret
|
1934
1915
|
# the RGB value (e.g. sRGB, Adobe RGB, DCI-P3, BT.2020, etc.). By default,
|
1935
|
-
# applications
|
1936
|
-
#
|
1937
|
-
#
|
1938
|
-
#
|
1939
|
-
#
|
1940
|
-
# protocolor.
|
1941
|
-
#
|
1942
|
-
#
|
1943
|
-
# float
|
1944
|
-
# float
|
1945
|
-
#
|
1946
|
-
#
|
1947
|
-
#
|
1948
|
-
#
|
1949
|
-
#
|
1950
|
-
#
|
1951
|
-
#
|
1952
|
-
#
|
1953
|
-
#
|
1954
|
-
#
|
1955
|
-
#
|
1956
|
-
#
|
1957
|
-
#
|
1958
|
-
#
|
1959
|
-
#
|
1916
|
+
# applications should assume the sRGB color space. When color equality needs to
|
1917
|
+
# be decided, implementations, unless documented otherwise, treat two colors as
|
1918
|
+
# equal if all their red, green, blue, and alpha values each differ by at most
|
1919
|
+
# 1e-5. Example (Java): import com.google.type.Color; // ... public static java.
|
1920
|
+
# awt.Color fromProto(Color protocolor) ` float alpha = protocolor.hasAlpha() ?
|
1921
|
+
# protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.
|
1922
|
+
# getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); ` public static
|
1923
|
+
# Color toProto(java.awt.Color color) ` float red = (float) color.getRed();
|
1924
|
+
# float green = (float) color.getGreen(); float blue = (float) color.getBlue();
|
1925
|
+
# float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .
|
1926
|
+
# setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue /
|
1927
|
+
# denominator); int alpha = color.getAlpha(); if (alpha != 255) ` result.
|
1928
|
+
# setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .
|
1929
|
+
# build()); ` return resultBuilder.build(); ` // ... Example (iOS / Obj-C): // ..
|
1930
|
+
# . static UIColor* fromProto(Color* protocolor) ` float red = [protocolor red];
|
1931
|
+
# float green = [protocolor green]; float blue = [protocolor blue]; FloatValue*
|
1932
|
+
# alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper !=
|
1933
|
+
# nil) ` alpha = [alpha_wrapper value]; ` return [UIColor colorWithRed:red green:
|
1934
|
+
# green blue:blue alpha:alpha]; ` static Color* toProto(UIColor* color) `
|
1935
|
+
# CGFloat red, green, blue, alpha; if (![color getRed:&red green:&green blue:&
|
1936
|
+
# blue alpha:&alpha]) ` return nil; ` Color* result = [[Color alloc] init]; [
|
1937
|
+
# result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha <
|
1938
|
+
# = 0.9999) ` [result setAlpha:floatWrapperWithValue(alpha)]; ` [result
|
1939
|
+
# autorelease]; return result; ` // ... Example (JavaScript): // ... var
|
1940
|
+
# protoToCssColor = function(rgb_color) ` var redFrac = rgb_color.red || 0.0;
|
1960
1941
|
# var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0;
|
1961
1942
|
# var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255);
|
1962
1943
|
# var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) ` return
|
1963
|
-
#
|
1944
|
+
# rgbToCssColor(red, green, blue); ` var alphaFrac = rgb_color.alpha.value || 0.
|
1964
1945
|
# 0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',
|
1965
|
-
# ', alphaFrac, ')'].join(''); `; var
|
1966
|
-
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var
|
1967
|
-
#
|
1968
|
-
#
|
1969
|
-
#
|
1970
|
-
#
|
1946
|
+
# ', alphaFrac, ')'].join(''); `; var rgbToCssColor = function(red, green, blue)
|
1947
|
+
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var hexString
|
1948
|
+
# = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var
|
1949
|
+
# resultBuilder = ['#']; for (var i = 0; i < missingZeros; i++) ` resultBuilder.
|
1950
|
+
# push('0'); ` resultBuilder.push(hexString); return resultBuilder.join(''); `; /
|
1951
|
+
# / ...
|
1971
1952
|
# Corresponds to the JSON property `color`
|
1972
1953
|
# @return [Google::Apis::DocumentaiV1beta2::GoogleTypeColor]
|
1973
1954
|
attr_accessor :color
|
@@ -2201,7 +2182,7 @@ module Google
|
|
2201
2182
|
# @return [Float]
|
2202
2183
|
attr_accessor :x
|
2203
2184
|
|
2204
|
-
# Y coordinate.
|
2185
|
+
# Y coordinate (starts from the top of the image).
|
2205
2186
|
# Corresponds to the JSON property `y`
|
2206
2187
|
# @return [Float]
|
2207
2188
|
attr_accessor :y
|
@@ -2322,7 +2303,7 @@ module Google
|
|
2322
2303
|
# @return [Fixnum]
|
2323
2304
|
attr_accessor :x
|
2324
2305
|
|
2325
|
-
# Y coordinate.
|
2306
|
+
# Y coordinate (starts from the top of the image).
|
2326
2307
|
# Corresponds to the JSON property `y`
|
2327
2308
|
# @return [Fixnum]
|
2328
2309
|
attr_accessor :y
|
@@ -3611,98 +3592,98 @@ module Google
|
|
3611
3592
|
|
3612
3593
|
# Represents a color in the RGBA color space. This representation is designed
|
3613
3594
|
# for simplicity of conversion to/from color representations in various
|
3614
|
-
# languages over compactness
|
3615
|
-
# be trivially provided to the constructor of
|
3616
|
-
# also be trivially provided to UIColor's
|
3595
|
+
# languages over compactness. For example, the fields of this representation can
|
3596
|
+
# be trivially provided to the constructor of `java.awt.Color` in Java; it can
|
3597
|
+
# also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha`
|
3617
3598
|
# method in iOS; and, with just a little work, it can be easily formatted into a
|
3618
|
-
# CSS
|
3599
|
+
# CSS `rgba()` string in JavaScript. This reference page doesn't carry
|
3619
3600
|
# information about the absolute color space that should be used to interpret
|
3620
3601
|
# the RGB value (e.g. sRGB, Adobe RGB, DCI-P3, BT.2020, etc.). By default,
|
3621
|
-
# applications
|
3622
|
-
#
|
3623
|
-
#
|
3624
|
-
#
|
3625
|
-
#
|
3626
|
-
# protocolor.
|
3627
|
-
#
|
3628
|
-
#
|
3629
|
-
# float
|
3630
|
-
# float
|
3631
|
-
#
|
3632
|
-
#
|
3633
|
-
#
|
3634
|
-
#
|
3635
|
-
#
|
3636
|
-
#
|
3637
|
-
#
|
3638
|
-
#
|
3639
|
-
#
|
3640
|
-
#
|
3641
|
-
#
|
3642
|
-
#
|
3643
|
-
#
|
3644
|
-
#
|
3645
|
-
#
|
3602
|
+
# applications should assume the sRGB color space. When color equality needs to
|
3603
|
+
# be decided, implementations, unless documented otherwise, treat two colors as
|
3604
|
+
# equal if all their red, green, blue, and alpha values each differ by at most
|
3605
|
+
# 1e-5. Example (Java): import com.google.type.Color; // ... public static java.
|
3606
|
+
# awt.Color fromProto(Color protocolor) ` float alpha = protocolor.hasAlpha() ?
|
3607
|
+
# protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.
|
3608
|
+
# getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); ` public static
|
3609
|
+
# Color toProto(java.awt.Color color) ` float red = (float) color.getRed();
|
3610
|
+
# float green = (float) color.getGreen(); float blue = (float) color.getBlue();
|
3611
|
+
# float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .
|
3612
|
+
# setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue /
|
3613
|
+
# denominator); int alpha = color.getAlpha(); if (alpha != 255) ` result.
|
3614
|
+
# setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .
|
3615
|
+
# build()); ` return resultBuilder.build(); ` // ... Example (iOS / Obj-C): // ..
|
3616
|
+
# . static UIColor* fromProto(Color* protocolor) ` float red = [protocolor red];
|
3617
|
+
# float green = [protocolor green]; float blue = [protocolor blue]; FloatValue*
|
3618
|
+
# alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper !=
|
3619
|
+
# nil) ` alpha = [alpha_wrapper value]; ` return [UIColor colorWithRed:red green:
|
3620
|
+
# green blue:blue alpha:alpha]; ` static Color* toProto(UIColor* color) `
|
3621
|
+
# CGFloat red, green, blue, alpha; if (![color getRed:&red green:&green blue:&
|
3622
|
+
# blue alpha:&alpha]) ` return nil; ` Color* result = [[Color alloc] init]; [
|
3623
|
+
# result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha <
|
3624
|
+
# = 0.9999) ` [result setAlpha:floatWrapperWithValue(alpha)]; ` [result
|
3625
|
+
# autorelease]; return result; ` // ... Example (JavaScript): // ... var
|
3626
|
+
# protoToCssColor = function(rgb_color) ` var redFrac = rgb_color.red || 0.0;
|
3646
3627
|
# var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0;
|
3647
3628
|
# var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255);
|
3648
3629
|
# var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) ` return
|
3649
|
-
#
|
3630
|
+
# rgbToCssColor(red, green, blue); ` var alphaFrac = rgb_color.alpha.value || 0.
|
3650
3631
|
# 0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',
|
3651
|
-
# ', alphaFrac, ')'].join(''); `; var
|
3652
|
-
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var
|
3653
|
-
#
|
3654
|
-
#
|
3655
|
-
#
|
3656
|
-
#
|
3632
|
+
# ', alphaFrac, ')'].join(''); `; var rgbToCssColor = function(red, green, blue)
|
3633
|
+
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var hexString
|
3634
|
+
# = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var
|
3635
|
+
# resultBuilder = ['#']; for (var i = 0; i < missingZeros; i++) ` resultBuilder.
|
3636
|
+
# push('0'); ` resultBuilder.push(hexString); return resultBuilder.join(''); `; /
|
3637
|
+
# / ...
|
3657
3638
|
# Corresponds to the JSON property `backgroundColor`
|
3658
3639
|
# @return [Google::Apis::DocumentaiV1beta2::GoogleTypeColor]
|
3659
3640
|
attr_accessor :background_color
|
3660
3641
|
|
3661
3642
|
# Represents a color in the RGBA color space. This representation is designed
|
3662
3643
|
# for simplicity of conversion to/from color representations in various
|
3663
|
-
# languages over compactness
|
3664
|
-
# be trivially provided to the constructor of
|
3665
|
-
# also be trivially provided to UIColor's
|
3644
|
+
# languages over compactness. For example, the fields of this representation can
|
3645
|
+
# be trivially provided to the constructor of `java.awt.Color` in Java; it can
|
3646
|
+
# also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha`
|
3666
3647
|
# method in iOS; and, with just a little work, it can be easily formatted into a
|
3667
|
-
# CSS
|
3648
|
+
# CSS `rgba()` string in JavaScript. This reference page doesn't carry
|
3668
3649
|
# information about the absolute color space that should be used to interpret
|
3669
3650
|
# the RGB value (e.g. sRGB, Adobe RGB, DCI-P3, BT.2020, etc.). By default,
|
3670
|
-
# applications
|
3671
|
-
#
|
3672
|
-
#
|
3673
|
-
#
|
3674
|
-
#
|
3675
|
-
# protocolor.
|
3676
|
-
#
|
3677
|
-
#
|
3678
|
-
# float
|
3679
|
-
# float
|
3680
|
-
#
|
3681
|
-
#
|
3682
|
-
#
|
3683
|
-
#
|
3684
|
-
#
|
3685
|
-
#
|
3686
|
-
#
|
3687
|
-
#
|
3688
|
-
#
|
3689
|
-
#
|
3690
|
-
#
|
3691
|
-
#
|
3692
|
-
#
|
3693
|
-
#
|
3694
|
-
#
|
3651
|
+
# applications should assume the sRGB color space. When color equality needs to
|
3652
|
+
# be decided, implementations, unless documented otherwise, treat two colors as
|
3653
|
+
# equal if all their red, green, blue, and alpha values each differ by at most
|
3654
|
+
# 1e-5. Example (Java): import com.google.type.Color; // ... public static java.
|
3655
|
+
# awt.Color fromProto(Color protocolor) ` float alpha = protocolor.hasAlpha() ?
|
3656
|
+
# protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.
|
3657
|
+
# getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); ` public static
|
3658
|
+
# Color toProto(java.awt.Color color) ` float red = (float) color.getRed();
|
3659
|
+
# float green = (float) color.getGreen(); float blue = (float) color.getBlue();
|
3660
|
+
# float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .
|
3661
|
+
# setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue /
|
3662
|
+
# denominator); int alpha = color.getAlpha(); if (alpha != 255) ` result.
|
3663
|
+
# setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .
|
3664
|
+
# build()); ` return resultBuilder.build(); ` // ... Example (iOS / Obj-C): // ..
|
3665
|
+
# . static UIColor* fromProto(Color* protocolor) ` float red = [protocolor red];
|
3666
|
+
# float green = [protocolor green]; float blue = [protocolor blue]; FloatValue*
|
3667
|
+
# alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper !=
|
3668
|
+
# nil) ` alpha = [alpha_wrapper value]; ` return [UIColor colorWithRed:red green:
|
3669
|
+
# green blue:blue alpha:alpha]; ` static Color* toProto(UIColor* color) `
|
3670
|
+
# CGFloat red, green, blue, alpha; if (![color getRed:&red green:&green blue:&
|
3671
|
+
# blue alpha:&alpha]) ` return nil; ` Color* result = [[Color alloc] init]; [
|
3672
|
+
# result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha <
|
3673
|
+
# = 0.9999) ` [result setAlpha:floatWrapperWithValue(alpha)]; ` [result
|
3674
|
+
# autorelease]; return result; ` // ... Example (JavaScript): // ... var
|
3675
|
+
# protoToCssColor = function(rgb_color) ` var redFrac = rgb_color.red || 0.0;
|
3695
3676
|
# var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0;
|
3696
3677
|
# var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255);
|
3697
3678
|
# var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) ` return
|
3698
|
-
#
|
3679
|
+
# rgbToCssColor(red, green, blue); ` var alphaFrac = rgb_color.alpha.value || 0.
|
3699
3680
|
# 0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',
|
3700
|
-
# ', alphaFrac, ')'].join(''); `; var
|
3701
|
-
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var
|
3702
|
-
#
|
3703
|
-
#
|
3704
|
-
#
|
3705
|
-
#
|
3681
|
+
# ', alphaFrac, ')'].join(''); `; var rgbToCssColor = function(red, green, blue)
|
3682
|
+
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var hexString
|
3683
|
+
# = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var
|
3684
|
+
# resultBuilder = ['#']; for (var i = 0; i < missingZeros; i++) ` resultBuilder.
|
3685
|
+
# push('0'); ` resultBuilder.push(hexString); return resultBuilder.join(''); `; /
|
3686
|
+
# / ...
|
3706
3687
|
# Corresponds to the JSON property `color`
|
3707
3688
|
# @return [Google::Apis::DocumentaiV1beta2::GoogleTypeColor]
|
3708
3689
|
attr_accessor :color
|
@@ -4036,7 +4017,7 @@ module Google
|
|
4036
4017
|
# @return [Float]
|
4037
4018
|
attr_accessor :x
|
4038
4019
|
|
4039
|
-
# Y coordinate.
|
4020
|
+
# Y coordinate (starts from the top of the image).
|
4040
4021
|
# Corresponds to the JSON property `y`
|
4041
4022
|
# @return [Float]
|
4042
4023
|
attr_accessor :y
|
@@ -4320,7 +4301,7 @@ module Google
|
|
4320
4301
|
# @return [Fixnum]
|
4321
4302
|
attr_accessor :x
|
4322
4303
|
|
4323
|
-
# Y coordinate.
|
4304
|
+
# Y coordinate (starts from the top of the image).
|
4324
4305
|
# Corresponds to the JSON property `y`
|
4325
4306
|
# @return [Fixnum]
|
4326
4307
|
attr_accessor :y
|
@@ -4702,61 +4683,60 @@ module Google
|
|
4702
4683
|
|
4703
4684
|
# Represents a color in the RGBA color space. This representation is designed
|
4704
4685
|
# for simplicity of conversion to/from color representations in various
|
4705
|
-
# languages over compactness
|
4706
|
-
# be trivially provided to the constructor of
|
4707
|
-
# also be trivially provided to UIColor's
|
4686
|
+
# languages over compactness. For example, the fields of this representation can
|
4687
|
+
# be trivially provided to the constructor of `java.awt.Color` in Java; it can
|
4688
|
+
# also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha`
|
4708
4689
|
# method in iOS; and, with just a little work, it can be easily formatted into a
|
4709
|
-
# CSS
|
4690
|
+
# CSS `rgba()` string in JavaScript. This reference page doesn't carry
|
4710
4691
|
# information about the absolute color space that should be used to interpret
|
4711
4692
|
# the RGB value (e.g. sRGB, Adobe RGB, DCI-P3, BT.2020, etc.). By default,
|
4712
|
-
# applications
|
4713
|
-
#
|
4714
|
-
#
|
4715
|
-
#
|
4716
|
-
#
|
4717
|
-
# protocolor.
|
4718
|
-
#
|
4719
|
-
#
|
4720
|
-
# float
|
4721
|
-
# float
|
4722
|
-
#
|
4723
|
-
#
|
4724
|
-
#
|
4725
|
-
#
|
4726
|
-
#
|
4727
|
-
#
|
4728
|
-
#
|
4729
|
-
#
|
4730
|
-
#
|
4731
|
-
#
|
4732
|
-
#
|
4733
|
-
#
|
4734
|
-
#
|
4735
|
-
#
|
4736
|
-
#
|
4693
|
+
# applications should assume the sRGB color space. When color equality needs to
|
4694
|
+
# be decided, implementations, unless documented otherwise, treat two colors as
|
4695
|
+
# equal if all their red, green, blue, and alpha values each differ by at most
|
4696
|
+
# 1e-5. Example (Java): import com.google.type.Color; // ... public static java.
|
4697
|
+
# awt.Color fromProto(Color protocolor) ` float alpha = protocolor.hasAlpha() ?
|
4698
|
+
# protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.
|
4699
|
+
# getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); ` public static
|
4700
|
+
# Color toProto(java.awt.Color color) ` float red = (float) color.getRed();
|
4701
|
+
# float green = (float) color.getGreen(); float blue = (float) color.getBlue();
|
4702
|
+
# float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .
|
4703
|
+
# setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue /
|
4704
|
+
# denominator); int alpha = color.getAlpha(); if (alpha != 255) ` result.
|
4705
|
+
# setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .
|
4706
|
+
# build()); ` return resultBuilder.build(); ` // ... Example (iOS / Obj-C): // ..
|
4707
|
+
# . static UIColor* fromProto(Color* protocolor) ` float red = [protocolor red];
|
4708
|
+
# float green = [protocolor green]; float blue = [protocolor blue]; FloatValue*
|
4709
|
+
# alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper !=
|
4710
|
+
# nil) ` alpha = [alpha_wrapper value]; ` return [UIColor colorWithRed:red green:
|
4711
|
+
# green blue:blue alpha:alpha]; ` static Color* toProto(UIColor* color) `
|
4712
|
+
# CGFloat red, green, blue, alpha; if (![color getRed:&red green:&green blue:&
|
4713
|
+
# blue alpha:&alpha]) ` return nil; ` Color* result = [[Color alloc] init]; [
|
4714
|
+
# result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha <
|
4715
|
+
# = 0.9999) ` [result setAlpha:floatWrapperWithValue(alpha)]; ` [result
|
4716
|
+
# autorelease]; return result; ` // ... Example (JavaScript): // ... var
|
4717
|
+
# protoToCssColor = function(rgb_color) ` var redFrac = rgb_color.red || 0.0;
|
4737
4718
|
# var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0;
|
4738
4719
|
# var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255);
|
4739
4720
|
# var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) ` return
|
4740
|
-
#
|
4721
|
+
# rgbToCssColor(red, green, blue); ` var alphaFrac = rgb_color.alpha.value || 0.
|
4741
4722
|
# 0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',
|
4742
|
-
# ', alphaFrac, ')'].join(''); `; var
|
4743
|
-
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var
|
4744
|
-
#
|
4745
|
-
#
|
4746
|
-
#
|
4747
|
-
#
|
4723
|
+
# ', alphaFrac, ')'].join(''); `; var rgbToCssColor = function(red, green, blue)
|
4724
|
+
# ` var rgbNumber = new Number((red << 16) | (green << 8) | blue); var hexString
|
4725
|
+
# = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var
|
4726
|
+
# resultBuilder = ['#']; for (var i = 0; i < missingZeros; i++) ` resultBuilder.
|
4727
|
+
# push('0'); ` resultBuilder.push(hexString); return resultBuilder.join(''); `; /
|
4728
|
+
# / ...
|
4748
4729
|
class GoogleTypeColor
|
4749
4730
|
include Google::Apis::Core::Hashable
|
4750
4731
|
|
4751
4732
|
# The fraction of this color that should be applied to the pixel. That is, the
|
4752
|
-
# final pixel color is defined by the equation: pixel color = alpha * (this
|
4753
|
-
# color) + (1.0 - alpha) * (background color) This means that a value of 1.0
|
4733
|
+
# final pixel color is defined by the equation: `pixel color = alpha * (this
|
4734
|
+
# color) + (1.0 - alpha) * (background color)` This means that a value of 1.0
|
4754
4735
|
# corresponds to a solid color, whereas a value of 0.0 corresponds to a
|
4755
4736
|
# completely transparent color. This uses a wrapper message rather than a simple
|
4756
4737
|
# float scalar so that it is possible to distinguish between a default value and
|
4757
|
-
# the value being unset. If omitted, this color object is
|
4758
|
-
#
|
4759
|
-
# 0).
|
4738
|
+
# the value being unset. If omitted, this color object is rendered as a solid
|
4739
|
+
# color (as if the alpha value had been explicitly given a value of 1.0).
|
4760
4740
|
# Corresponds to the JSON property `alpha`
|
4761
4741
|
# @return [Float]
|
4762
4742
|
attr_accessor :alpha
|
@@ -16,13 +16,13 @@ module Google
|
|
16
16
|
module Apis
|
17
17
|
module DocumentaiV1beta2
|
18
18
|
# Version of the google-apis-documentai_v1beta2 gem
|
19
|
-
GEM_VERSION = "0.
|
19
|
+
GEM_VERSION = "0.8.0"
|
20
20
|
|
21
21
|
# Version of the code generator used to generate this client
|
22
22
|
GENERATOR_VERSION = "0.2.0"
|
23
23
|
|
24
24
|
# Revision of the discovery document this client was generated from
|
25
|
-
REVISION = "
|
25
|
+
REVISION = "20210329"
|
26
26
|
end
|
27
27
|
end
|
28
28
|
end
|
@@ -100,12 +100,6 @@ module Google
|
|
100
100
|
include Google::Apis::Core::JsonObjectSupport
|
101
101
|
end
|
102
102
|
|
103
|
-
class GoogleCloudDocumentaiUiv1beta3SampleDatasetMetadata
|
104
|
-
class Representation < Google::Apis::Core::JsonRepresentation; end
|
105
|
-
|
106
|
-
include Google::Apis::Core::JsonObjectSupport
|
107
|
-
end
|
108
|
-
|
109
103
|
class GoogleCloudDocumentaiUiv1beta3SetDefaultProcessorVersionMetadata
|
110
104
|
class Representation < Google::Apis::Core::JsonRepresentation; end
|
111
105
|
|
@@ -961,14 +955,6 @@ module Google
|
|
961
955
|
end
|
962
956
|
end
|
963
957
|
|
964
|
-
class GoogleCloudDocumentaiUiv1beta3SampleDatasetMetadata
|
965
|
-
# @private
|
966
|
-
class Representation < Google::Apis::Core::JsonRepresentation
|
967
|
-
property :common_metadata, as: 'commonMetadata', class: Google::Apis::DocumentaiV1beta2::GoogleCloudDocumentaiUiv1beta3CommonOperationMetadata, decorator: Google::Apis::DocumentaiV1beta2::GoogleCloudDocumentaiUiv1beta3CommonOperationMetadata::Representation
|
968
|
-
|
969
|
-
end
|
970
|
-
end
|
971
|
-
|
972
958
|
class GoogleCloudDocumentaiUiv1beta3SetDefaultProcessorVersionMetadata
|
973
959
|
# @private
|
974
960
|
class Representation < Google::Apis::Core::JsonRepresentation
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-apis-documentai_v1beta2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-04-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: google-apis-core
|
@@ -52,7 +52,7 @@ licenses:
|
|
52
52
|
metadata:
|
53
53
|
bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
|
54
54
|
changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/master/generated/google-apis-documentai_v1beta2/CHANGELOG.md
|
55
|
-
documentation_uri: https://googleapis.dev/ruby/google-apis-documentai_v1beta2/v0.
|
55
|
+
documentation_uri: https://googleapis.dev/ruby/google-apis-documentai_v1beta2/v0.8.0
|
56
56
|
source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/master/generated/google-apis-documentai_v1beta2
|
57
57
|
post_install_message:
|
58
58
|
rdoc_options: []
|