Search in sources :

Example 1 with State

use of org.onosproject.net.Link.State in project onos by opennetworkinglab.

the class DefaultLinkSerializer method read.

@Override
public DefaultLink read(Kryo kryo, Input input, Class<DefaultLink> type) {
    ProviderId providerId = (ProviderId) kryo.readClassAndObject(input);
    ConnectPoint src = (ConnectPoint) kryo.readClassAndObject(input);
    ConnectPoint dst = (ConnectPoint) kryo.readClassAndObject(input);
    Type linkType = (Type) kryo.readClassAndObject(input);
    State state = (State) kryo.readClassAndObject(input);
    boolean isDurable = input.readBoolean();
    return DefaultLink.builder().providerId(providerId).src(src).dst(dst).type(linkType).state(state).isExpected(isDurable).build();
}
Also used : ProviderId(org.onosproject.net.provider.ProviderId) Type(org.onosproject.net.Link.Type) State(org.onosproject.net.Link.State) ConnectPoint(org.onosproject.net.ConnectPoint)

Aggregations

ConnectPoint (org.onosproject.net.ConnectPoint)1 State (org.onosproject.net.Link.State)1 Type (org.onosproject.net.Link.Type)1 ProviderId (org.onosproject.net.provider.ProviderId)1