fixed up the names of new site names/slices to be more PLC compatible
[sfa.git] / sfa / methods / register.py
1 ### $Id$
2 ### $URL$
3
4 from sfa.trust.certificate import Keypair, convert_public_key
5 from sfa.trust.gid import *
6 from sfa.util.faults import *
7 from sfa.util.method import Method
8 from sfa.util.parameter import Parameter, Mixed
9 from sfa.methods.Register import Register
10
11 class register(Register):
12     """
13     Deprecated. Used Register instead.
14
15     Register an object with the registry. In addition to being stored in the
16     SFA database, the appropriate records will also be created in the
17     PLC databases
18     
19     @param cred credential string
20     @param record_dict dictionary containing record fields
21     
22     @return gid string representation
23     """
24
25     interfaces = ['registry']
26     
27     accepts = [
28         Parameter(str, "Credential string"),
29         Parameter(dict, "Record dictionary containing record fields")
30         ]
31
32     returns = Parameter(int, "String representation of gid object")
33     
34     def call(self, cred, record, origin_hrn=None):
35         
36         return Register.call(self, record, cred)