Free cookie consent management tool by TermsFeed Policy Generator

source: trunk/sources/HeuristicLab.Services.OKB/3.3/Interfaces/IRunnerService.cs @ 4313

Last change on this file since 4313 was 4313, checked in by swagner, 14 years ago

Worked on OKB user authentication (#1167)

File size: 4.1 KB
Line 
1#region License Information
2/* HeuristicLab
3 * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
4 *
5 * This file is part of HeuristicLab.
6 *
7 * HeuristicLab is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * HeuristicLab is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
19 */
20#endregion
21
22using System.Net.Security;
23using System.ServiceModel;
24using HeuristicLab.Services.OKB.DataAccess;
25
26namespace HeuristicLab.Services.OKB {
27
28  /// <summary>
29  /// Service interface for submitting new <see cref="Experiment"/> <see cref="Run"/>s.
30  /// </summary>
31  [ServiceContract(SessionMode = SessionMode.Required, ProtectionLevel = ProtectionLevel.EncryptAndSign)]
32  public interface IRunnerService {
33
34    /// <summary>
35    /// Logs the current user in. In case the user or client
36    /// does not exist yet, they are created on the server. This
37    /// method is currently not used for authentication but merely
38    /// for auditing.
39    /// </summary>
40    /// <param name="clientname">The clientname.</param>
41    /// <returns><c>true</c> if the login was successful; <c>false</c> otherwise.</returns>
42    [OperationContract(IsInitiating = true)]
43    bool Login(string clientname);
44
45    /// <summary>
46    /// Gets a <see cref="StarterKit"/>: A partially populated object
47    /// graph to enable selection of algorithm and problem for a certain
48    /// platofrm.
49    /// </summary>
50    /// <param name="platformName">Name of the platform.</param>
51    /// <returns>A <see cref="StarterKit"/>.</returns>
52    [OperationContract(IsInitiating = false)]
53    StarterKit GetStarterKit(string platformName);
54
55    /// <summary>
56    /// Get all necessary information to conduct an experiment. This retrieves the
57    /// <see cref="Algorithm"/>'s:
58    /// <list type="bullet">
59    /// <item><see cref="Parameter"/>s</item>
60    /// <item><see cref="Result"/>s</item>
61    /// <item>and their respective <see cref="DataType"/>s</item>
62    /// </list>
63    /// as well as the <see cref="Problem"/>'s:
64    /// <list>
65    /// <item><see cref="SolutionRepresentation"/></item>
66    /// <item><see cref="Parameter"/>s</item>
67    /// </list>
68    /// </summary>
69    /// <param name="algorithm">The algorithm.</param>
70    /// <param name="problem">The problem.</param>
71    /// <returns>A more complete object graph contained in an
72    /// <see cref="ExperimentKit"/>.</returns>
73    [OperationContract(IsInitiating = false)]
74    ExperimentKit PrepareExperiment(Algorithm algorithm, Problem problem);
75
76    /// <summary>
77    /// Adds the a new <see cref="Experiment"/> <see cref="Run"/>.
78    ///
79    /// The <see cref="Experiment"/> is created if necessary as well as
80    /// all <see cref="Parameter"/>s and <see cref="Result"/>s. If an
81    /// identical experiment has been conducted before the new run is
82    /// linked to this previous experiment instead.
83    /// </summary>
84    /// <param name="algorithm">The algorithm.</param>
85    /// <param name="problem">The problem.</param>
86    /// <param name="project">The project.</param>
87    [OperationContract(IsInitiating = false)]
88    void AddRun(Algorithm algorithm, Problem problem, Project project);
89
90    /// <summary>
91    /// Determines whether this instance is connected.
92    /// </summary>
93    /// <returns>
94    ///   <c>true</c> if this instance is connected; otherwise, <c>false</c>.
95    /// </returns>
96    [OperationContract(IsInitiating = false)]
97    bool IsConnected();
98
99    /// <summary>
100    /// Logout out and closes the connection.
101    /// </summary>
102    [OperationContract(IsInitiating = false, IsTerminating = true, IsOneWay = true)]
103    void Logout();
104  }
105
106}
Note: See TracBrowser for help on using the repository browser.