source: trunk/CrypPlugins/PeerToPeerWorker_NEW/IControlWorker.cs @ 1448

Last change on this file since 1448 was 1448, checked in by Sven Rech, 12 years ago

replaced all BigInteger stuff with the new BigInteger class from .net 4.0

But there are still problems with some plugins (Keysearcher, BigInteger Operations...)

File size: 1.8 KB
Line 
1/* Copyright 2010 Team CrypTool (Christian Arnold), Uni Duisburg-Essen
2
3   Licensed under the Apache License, Version 2.0 (the "License");
4   you may not use this file except in compliance with the License.
5   You may obtain a copy of the License at
6
7       http://www.apache.org/licenses/LICENSE-2.0
8
9   Unless required by applicable law or agreed to in writing, software
10   distributed under the License is distributed on an "AS IS" BASIS,
11   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12   See the License for the specific language governing permissions and
13   limitations under the License.
14*/
15
16using System;
17using System.Collections.Generic;
18using System.Linq;
19using System.Text;
20using Cryptool.Plugins.PeerToPeer.Jobs;
21using Cryptool.PluginBase.Miscellaneous;
22using System.Numerics;
23
24namespace Cryptool.PluginBase.Control
25{
26    /// <summary>
27    /// Every PlugIn, which derives from this interface have to implement
28    /// the logics for processing a distributed JobPart
29    /// </summary>
30    public interface IControlWorker
31    {
32        event ProcessingSuccessfullyEnded OnProcessingSuccessfullyEnded;
33        event ProcessingCanceled OnProcessingCanceled;
34        event InfoText OnInfoTextReceived;
35
36        string TopicName { get; set; }
37
38        /// <summary>
39        /// tries to deserialize byte representation of a job. If this is possible,
40        /// JobAccepted event will be thrown, otherwise JobDeclined event will be thrown.
41        /// Catch OnProcessingStarted-Event to get result of this operation!
42        /// </summary>
43        /// <param name="job">byte representation of a job</param>
44        bool StartProcessing(byte[] job, out BigInteger jobId);
45        void StopProcessing();
46    }
47}
Note: See TracBrowser for help on using the repository browser.