Last change
on this file since 15014 was
15014,
checked in by pfleck, 7 years ago
|
Added code and tools for the ExternalEvaluationProblem. (e.g. Java-side evaluation)
|
File size:
658 bytes
|
Line | |
---|
1 | package com.heuristiclab.problems.externalevaluation;
|
---|
2 |
|
---|
3 | import java.io.*;
|
---|
4 | import com.google.protobuf.*;
|
---|
5 |
|
---|
6 | public abstract class Channel implements IChannel {
|
---|
7 | protected boolean initialized;
|
---|
8 |
|
---|
9 | protected Channel() {
|
---|
10 | }
|
---|
11 |
|
---|
12 | @Override
|
---|
13 | public boolean isInitialized() {
|
---|
14 | return initialized;
|
---|
15 | }
|
---|
16 |
|
---|
17 | @Override
|
---|
18 | public void open() throws IOException {
|
---|
19 | initialized = true;
|
---|
20 | }
|
---|
21 |
|
---|
22 | @Override
|
---|
23 | public abstract void send(Message msg) throws IOException;
|
---|
24 |
|
---|
25 | @Override
|
---|
26 | public abstract Message receive(Message.Builder builder) throws IOException;
|
---|
27 |
|
---|
28 | @Override
|
---|
29 | public void close() throws IOException {
|
---|
30 | initialized = false;
|
---|
31 | }
|
---|
32 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.