Java 类org.projectfloodlight.openflow.protocol.OFAggregateStatsReply 实例源码

项目:athena    文件:FeatureCollectorProvider.java   
@Override
public void aggregateStatsProcess(Dpid dpid, OFAggregateStatsReply reply) {
    //magic number
    if (reply.getXid() != 1126) {
        return;
    }
    AggregateStatisticsFeature asf = new AggregateStatisticsFeature();
    UnitAggregateStatistics uas =
            new UnitAggregateStatistics(reply.getPacketCount().getValue(),
                    reply.getByteCount().getValue(), reply.getFlowCount());

    Date date = new java.sql.Timestamp(Calendar.getInstance().getTime().getTime());

    uas.setDate(date);

    FeatureIndex fi = new FeatureIndex();


    fi.setSwitchDatapathId(dpid.value());

    asf.addFeatureData(fi, uas);

    providerService.aggregateStatsHandler(asf);
}
项目:fresco_floodlight    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:iTAP-controller    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:SDN-Multicast    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:arscheduler    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:floodlight1.2-delay    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:floodlight-hardware    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate");
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:ACAMPController    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:fast-failover-demo    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:floodlightLB    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:DSC    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:floodlight    文件:StatsReplySerializer.java   
public static void serializeAggregateReply(List<OFAggregateStatsReply> aggregateReplies, JsonGenerator jGen) throws IOException, JsonProcessingException{
    OFAggregateStatsReply aggregateReply = aggregateReplies.get(0); // There are only one aggregateReply from the switch
    jGen.writeObjectFieldStart("aggregate"); 
    jGen.writeStringField("version", aggregateReply.getVersion().toString()); //return the enum name
    jGen.writeNumberField("flowCount", aggregateReply.getFlowCount());
    jGen.writeNumberField("packetCount", aggregateReply.getPacketCount().getValue());
    jGen.writeNumberField("byteCount", aggregateReply.getByteCount().getValue());
    switch (aggregateReply.getVersion()) {
    case OF_10:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer10.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_11:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer11.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_12:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer12.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_13:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer13.toWireValue(aggregateReply.getFlags()));
        break;
    case OF_14:
        jGen.writeNumberField("flags", OFStatsReplyFlagsSerializerVer14.toWireValue(aggregateReply.getFlags()));
        break;
    default:
        break;
    }
    jGen.writeEndObject(); // end match
}
项目:fresco_floodlight    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:iTAP-controller    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:SDN-Multicast    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:arscheduler    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:floodlight1.2-delay    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:floodlight-hardware    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:ACAMPController    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:fast-failover-demo    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:floodlightLB    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:DSC    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:floodlight    文件:AggregateStatistics.java   
public static AggregateStatistics of(OFAggregateStatsReply statsReply) {
    return new AggregateStatistics(statsReply.getPacketCount(),
            statsReply.getByteCount(), statsReply.getFlowCount());
}
项目:athena    文件:OpenFlowStatisticsListener.java   
/**
 * Notify that the aggregate statistics event is arrived.
 * @param dpid the switch where the event occured.
 * @param reply the aggregate statistics.
 */
void aggregateStatsProcess(Dpid dpid, OFAggregateStatsReply reply);