_federation.pyi 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. #
  2. # Copyright 2019 The FATE Authors. All Rights Reserved.
  3. #
  4. # Licensed under the Apache License, Version 2.0 (the "License");
  5. # you may not use this file except in compliance with the License.
  6. # You may obtain a copy of the License at
  7. #
  8. # http://www.apache.org/licenses/LICENSE-2.0
  9. #
  10. # Unless required by applicable law or agreed to in writing, software
  11. # distributed under the License is distributed on an "AS IS" BASIS,
  12. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. # See the License for the specific language governing permissions and
  14. # limitations under the License.
  15. import typing
  16. from eggroll.roll_pair.roll_pair import RollPairContext
  17. from eggroll.roll_site.roll_site import RollSiteContext
  18. from fate_arch.abc import GarbageCollectionABC
  19. from fate_arch.common import Party
  20. class Federation(object):
  21. def __init__(self, rp_ctx: RollPairContext, rs_session_id: str, party: Party, proxy_endpoint: str):
  22. self._rsc: RollSiteContext = ...
  23. ...
  24. def get(self: Federation, name: str, tag: str, parties: typing.List[Party],
  25. gc: GarbageCollectionABC) -> typing.List: ...
  26. def remote(self, v, name: str, tag: str, parties: typing.List[Party],
  27. gc: GarbageCollectionABC) -> typing.NoReturn: ...
  28. def _remote(v,
  29. name: str,
  30. tag: str,
  31. parties: typing.List[typing.Tuple[str, str]],
  32. rsc: RollSiteContext,
  33. gc: GarbageCollectionABC) -> typing.NoReturn: ...
  34. def _get(name: str,
  35. tag: str,
  36. parties: typing.List[typing.Tuple[str, str]],
  37. rsc: RollSiteContext,
  38. gc: GarbageCollectionABC) -> typing.List: ...
  39. def _remote_tag_not_duplicate(name: str, tag: str, parties: typing.List[typing.Tuple[str, str]]): ...
  40. def _push_with_exception_handle(rsc: RollSiteContext, v, name: str, tag: str, parties: typing.List[typing.Tuple[str, str]]): ...
  41. def _get_tag_not_duplicate(name: str, tag: str, party: typing.Tuple[str, str]): ...
  42. def _get_value_post_process(v, name: str, tag: str, party: typing.Tuple[str, str], rsc: RollSiteContext,
  43. gc: GarbageCollectionABC): ...