UserAndLimitationManagementWs.asmx.cs 1.22 KB
Newer Older
Vaclav Svaton's avatar
Vaclav Svaton committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using HaaSMiddleware.ServiceTier.UserAndLimitationManagement;
using org.apache.etch.EtchServiceTier.types.EtchServiceTier;

namespace HaaSMiddleware.WebServices {
	/// <summary>
	/// Summary description for UserAndLimitationManagementWs
	/// </summary>
	[WebService(Namespace = "http://hpcaas.it4i.cz/")]
	[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
	[System.ComponentModel.ToolboxItem(false)]
	[System.Web.Script.Services.ScriptService]
	public class UserAndLimitationManagementWs : System.Web.Services.WebService {
		private IUserAndLimitationManagementService service = new UserAndLimitationManagementService();

		[WebMethod]
		public string AuthenticateUserPassword(PasswordCredentialsExt credentials) {
			return service.AuthenticateUser(credentials);
		}

		[WebMethod]
		public string AuthenticateUserDigitalSignature(DigitalSignatureCredentialsExt credentials) {
			return service.AuthenticateUser(credentials);
		}

		[WebMethod]
		public ResourceUsageExt[] GetCurrentUsageAndLimitationsForCurrentUser(string sessionCode) {
			return service.GetCurrentUsageAndLimitationsForCurrentUser(sessionCode);
		}
	}
}