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
36
37
38
39
40
41
42
43
44
45
46
//
// Data 
//
pub type DatasetID = String;

// 
// Cheminformatics 
//
pub type SMILES = String;
pub type SMARTS = String;
// Fingerprint Data 
pub type FPData = Vec<u32>;

//
// Computing Unit 
//
pub type SerializedFormat = String; 

//
// Trait 
// 
pub trait Operator {
    type InputType;
    type DataType;
    type OutputType;

    fn compute(&self, input: &Self::InputType, data: &Self::DataType) -> Self::OutputType;
}

pub trait OperatorOutput {
    fn new() -> Self;
    fn len(&self) -> usize;
    fn clear(&mut self);
    fn serialize(&self) -> String; 
    fn deserialize(content: &String) -> Self; 
}
pub trait ComputingUnit {
    fn compute(&mut self, args: &Option<SerializedFormat>);
    fn serialize_output(&self) -> SerializedFormat;
    fn output_len(&self) -> usize;
}

//
// Modules
// 
pub mod kinds;