@Override public String toString() { return "OVXPortStatus: reason[" + OFPortReason.fromReasonCode(this.reason).name() + "]" + " port[" + this.desc.getPortNumber() + "]"; }
public V6Error(OFError e) { this.length = (short)e.getLengthU(); this.errorType = e.getErrorType(); this.errorCode = e.getErrorCode(); this.xid = e.getXid(); }
@Override public OFMessage instantiate() { return new OFStatisticsRequest(); } }), STATS_REPLY(17, OFStatisticsReply.class,
@Override public int hashCode() { final int prime = 349; int result = super.hashCode(); result = prime * result + this.portNumber; return result; }
/** * Returns a new instance of the OFMessage represented by this OFType * * @return the new object */ public OFMessage newInstance() { return this.instantiable.instantiate(); }
public static OFPortReason fromReasonCode(final byte reason) { for (final OFPortReason r : OFPortReason.values()) { if (r.getReasonCode() == reason) { return r; } } return null; } }
@Override boolean isPartiallyOn(final int flags) { final int intValue = this.getInt(flags); return intValue > 0 && intValue < 32; }
@Override public OFMessage instantiate() { return new OFEchoRequest(); } }), ECHO_REPLY(3, OFEchoReply.class, new Instantiable<OFMessage>() {
@Override public OFMessage instantiate() { return new OFEchoReply(); } }), VENDOR(4, OFVendor.class, new Instantiable<OFMessage>() {
@Override public OFMessage instantiate() { return new OFGetConfigReply(); } }), SET_CONFIG(9, OFSetConfig.class, new Instantiable<OFMessage>() {
/** convenience constructor */ public OFError(final OFErrorType errorType) { this(); this.setErrorType(errorType); }
/** * convience method return a wildcard for an ofmatch that amtch on an * arbitrary number of set flags */ public static Wildcards ofMatches(final Wildcards.Flag... setFlags) { int flags = Wildcards.FULL_INT; for (final Wildcards.Flag flag : setFlags) { flags = flag.matchOn(flags); } return Wildcards.of(flags); }
@Override public int hashCode() { final int prime = 331; int result = super.hashCode(); result = prime * result + this.flags; result = prime * result + this.missSendLength; return result; }
/** * Returns a new instance of the SNMPAction represented by this SNMPActionType * @return the new object */ public SNMPAction newInstance() { return instantiable.instantiate(); }