blob: 3ef73dda57752134d0da941c67036a937accc66b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
# Copyright (C) by Josh Blum. See LICENSE.txt for licensing information.
import gras
class MyBlock(gras.Block):
def __init__(self):
gras.Block.__init__(self, "MyBlock")
self.foo = 0
self.register_call("get_num", self.get_num)
def work(self, *args): pass
def get_num(self):
return 42
gras.register_factory("/tests/my_block1", MyBlock)
|