fixed up the names of new site names/slices to be more PLC compatible
[sfa.git] / sfa / methods / redeem_ticket.py
1 ### $Id: reset_slice.py 15428 2009-10-23 15:28:03Z tmack $
2 ### $URL: https://svn.planet-lab.org/svn/sfa/trunk/sfacomponent/methods/reset_slice.py $
3 import xmlrpclib
4 from sfa.util.faults import *
5 from sfa.util.method import Method
6 from sfa.util.parameter import Parameter, Mixed
7 from sfa.methods.RedeemTicket import RedeemTicket
8
9 class redeem_ticket(RedeemTicket):
10     """
11     Deprecated. Use RedeemTicket instead.
12
13     Redeem a approved set of resource allocations (ticket).        
14
15     @param cred credential string specifying the rights of the caller
16     @param ticket 
17     @return 1 is successful, faults otherwise  
18     """
19
20     interfaces = ['component']
21     
22     accepts = [
23         Parameter(str, "Credential string representation of SFA credential"),
24         Parameter(str, "Ticket  string representation of SFA ticket")
25         ]
26
27     returns = [Parameter(int, "1 if successful")]
28     
29     def call(self, cred, ticket):
30
31         return RedeemTicket.call(self, ticket, cred)