public class PyActorClass extends Object
example_package/
├──__init__.py
└──example_module.py
in example_module.py there is an actor class A.
\@ray.remote
class A(object):
def __init__(self, x):
self.x = x
we can create this Python actor from Java:
PyActorHandle actor = Ray.createActor(PyActorClass.of("example_package.example_module", "A"),
"the value for x");
| Modifier and Type | Field and Description |
|---|---|
String |
className |
String |
moduleName |
| Modifier and Type | Method and Description |
|---|---|
static PyActorClass |
of(String moduleName,
String className)
Create a python actor class.
|
public static PyActorClass of(String moduleName, String className)
moduleName - The full module name of this actor classclassName - The name of this actor classCopyright © 2021. All rights reserved.