Skip to content

Commit a778761

Browse files
feat: Add support for REST transport (#194)
- [ ] Regenerate this pull request now. PiperOrigin-RevId: 474571730 Source-Link: googleapis/googleapis@5a9ee4d Source-Link: googleapis/googleapis-gen@ceafe52 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiY2VhZmU1MjFmMTM3NjgwZmRlZTJmOWNhOWUxOTQ3Y2RkODI1MDcwZCJ9 fix(deps): require google-api-core>=1.33.1,>=2.8.0 fix(deps): require protobuf >= 3.20.1
1 parent 7fcb994 commit a778761

File tree

32 files changed

+6764
-470
lines changed

32 files changed

+6764
-470
lines changed

packages/google-area120-tables/google/area120/tables_v1alpha1/gapic_metadata.json

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,71 @@
136136
]
137137
}
138138
}
139+
},
140+
"rest": {
141+
"libraryClient": "TablesServiceClient",
142+
"rpcs": {
143+
"BatchCreateRows": {
144+
"methods": [
145+
"batch_create_rows"
146+
]
147+
},
148+
"BatchDeleteRows": {
149+
"methods": [
150+
"batch_delete_rows"
151+
]
152+
},
153+
"BatchUpdateRows": {
154+
"methods": [
155+
"batch_update_rows"
156+
]
157+
},
158+
"CreateRow": {
159+
"methods": [
160+
"create_row"
161+
]
162+
},
163+
"DeleteRow": {
164+
"methods": [
165+
"delete_row"
166+
]
167+
},
168+
"GetRow": {
169+
"methods": [
170+
"get_row"
171+
]
172+
},
173+
"GetTable": {
174+
"methods": [
175+
"get_table"
176+
]
177+
},
178+
"GetWorkspace": {
179+
"methods": [
180+
"get_workspace"
181+
]
182+
},
183+
"ListRows": {
184+
"methods": [
185+
"list_rows"
186+
]
187+
},
188+
"ListTables": {
189+
"methods": [
190+
"list_tables"
191+
]
192+
},
193+
"ListWorkspaces": {
194+
"methods": [
195+
"list_workspaces"
196+
]
197+
},
198+
"UpdateRow": {
199+
"methods": [
200+
"update_row"
201+
]
202+
}
203+
}
139204
}
140205
}
141206
}

packages/google-area120-tables/google/area120/tables_v1alpha1/services/tables_service/client.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
from .transports.base import DEFAULT_CLIENT_INFO, TablesServiceTransport
4343
from .transports.grpc import TablesServiceGrpcTransport
4444
from .transports.grpc_asyncio import TablesServiceGrpcAsyncIOTransport
45+
from .transports.rest import TablesServiceRestTransport
4546

4647

4748
class TablesServiceClientMeta(type):
@@ -55,6 +56,7 @@ class TablesServiceClientMeta(type):
5556
_transport_registry = OrderedDict() # type: Dict[str, Type[TablesServiceTransport]]
5657
_transport_registry["grpc"] = TablesServiceGrpcTransport
5758
_transport_registry["grpc_asyncio"] = TablesServiceGrpcAsyncIOTransport
59+
_transport_registry["rest"] = TablesServiceRestTransport
5860

5961
def get_transport_class(
6062
cls,
@@ -387,6 +389,9 @@ def __init__(
387389
transport (Union[str, TablesServiceTransport]): The
388390
transport to use. If set to None, a transport is chosen
389391
automatically.
392+
NOTE: "rest" transport functionality is currently in a
393+
beta state (preview). We welcome your feedback via an
394+
issue in this library's source repository.
390395
client_options (google.api_core.client_options.ClientOptions): Custom options for the
391396
client. It won't take effect if a ``transport`` instance is provided.
392397
(1) The ``api_endpoint`` property can be used to override the

packages/google-area120-tables/google/area120/tables_v1alpha1/services/tables_service/transports/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,18 @@
1919
from .base import TablesServiceTransport
2020
from .grpc import TablesServiceGrpcTransport
2121
from .grpc_asyncio import TablesServiceGrpcAsyncIOTransport
22+
from .rest import TablesServiceRestInterceptor, TablesServiceRestTransport
2223

2324
# Compile a registry of transports.
2425
_transport_registry = OrderedDict() # type: Dict[str, Type[TablesServiceTransport]]
2526
_transport_registry["grpc"] = TablesServiceGrpcTransport
2627
_transport_registry["grpc_asyncio"] = TablesServiceGrpcAsyncIOTransport
28+
_transport_registry["rest"] = TablesServiceRestTransport
2729

2830
__all__ = (
2931
"TablesServiceTransport",
3032
"TablesServiceGrpcTransport",
3133
"TablesServiceGrpcAsyncIOTransport",
34+
"TablesServiceRestTransport",
35+
"TablesServiceRestInterceptor",
3236
)

0 commit comments

Comments
 (0)