@Test(expected = IllegalArgumentException.class) public void testGetValue_default() { PacketHeaderConstraints phc = PacketHeaderConstraints.unconstrained(); SRC_IP_EXTRACTOR.getValue(phc, null); }
@Override public Ip getValue(PacketHeaderConstraints phc, Location srcLocation) { String headerSrcIp = phc.getSrcIps(); if (headerSrcIp != null) { return _helper.inferSrcIpFromHeaderSrcIp(headerSrcIp); } checkArgument(srcLocation != null, "source location is missing"); return _helper.inferSrcIpFromSourceLocation(srcLocation); }
SrcIpExtractorLocation implements FieldExtractor<Ip> { @Override public Ip getValue(PacketHeaderConstraints phc, Location srcLocation) { String headerSrcIp = phc.getSrcIps(); if (headerSrcIp != null) { return _helper.inferSrcIpFromHeaderSrcIp(headerSrcIp); } checkArgument(srcLocation != null, "source location is missing"); return _helper.inferSrcIpFromSourceLocation(srcLocation); } }
SrcIpExtractorLocation implements FieldExtractor<Ip> { @Override public Ip getValue(PacketHeaderConstraints phc, Location srcLocation) { String headerSrcIp = phc.getSrcIps(); if (headerSrcIp != null) { return _helper.inferSrcIpFromHeaderSrcIp(headerSrcIp); } checkArgument(srcLocation != null, "source location is missing"); return _helper.inferSrcIpFromSourceLocation(srcLocation); } SrcIpExtractorLocation(IpFieldExtractorContext helper); }
SrcIpExtractorLocation implements FieldExtractor<Ip> { @Override public Ip getValue(PacketHeaderConstraints phc, Location srcLocation) { String headerSrcIp = phc.getSrcIps(); if (headerSrcIp != null) { return _helper.inferSrcIpFromHeaderSrcIp(headerSrcIp); } checkArgument(srcLocation != null, "source location is missing"); return _helper.inferSrcIpFromSourceLocation(srcLocation); } SrcIpExtractorLocation(IpFieldExtractorContext helper); @Override Ip getValue(PacketHeaderConstraints phc, Location srcLocation); }
SrcIpExtractorLocation implements FieldExtractor<Ip> { @Override public Ip getValue(PacketHeaderConstraints phc, Location srcLocation) { String headerSrcIp = phc.getSrcIps(); if (headerSrcIp != null) { return _helper.inferSrcIpFromHeaderSrcIp(headerSrcIp); } checkArgument(srcLocation != null, "source location is missing"); return _helper.inferSrcIpFromSourceLocation(srcLocation); } SrcIpExtractorLocation(IpFieldExtractorContext helper); @Override Ip getValue(PacketHeaderConstraints phc, Location srcLocation);  }