@Test public void testJsonSerialization() { CompletionMetadata completionMetadata = CompletionMetadata.builder() .setFilterNames(ImmutableSet.of("filter")) .setInterfaces(ImmutableSet.of(NodeInterfacePair.of("node", "interface"))) .setIps(ImmutableSet.of(Ip.parse("1.1.1.1"))) .setSourceLocations(ImmutableSet.of(new InterfaceLocation("node", "interface"))) .setMlagIds(ImmutableSet.of("mlag")) .setNodes(ImmutableSet.of("node")) .setPrefixes(ImmutableSet.of("prefix")) .setStructureNames(ImmutableSet.of("structure")) .setVrfs(ImmutableSet.of("vrf")) .setZones(ImmutableSet.of("zone")) .build(); assertThat( BatfishObjectMapper.clone(completionMetadata, CompletionMetadata.class), equalTo(completionMetadata)); }
public static @Nonnull Builder builder() { return new Builder(); }
CompletionMetadata implements Serializable { public static @Nonnull Builder builder() { return new Builder(); } }
CompletionMetadata implements Serializable { public static @Nonnull Builder builder() { return new Builder(); } CompletionMetadata(
      Set<String> filterNames,
      Set<NodeInterfacePair> interfaces,
      Map<Ip, IpCompletionMetadata> ips,
      Set<Location> sourceLocations,
      Set<String> mlagIds,
      Map<String, NodeCompletionMetadata> nodes,
      Set<String> prefixes,
      Set<String> routingPolicyNames,
      Set<String> structureNames,
      Set<String> vrfs,
      Set<String> zones); }
CompletionMetadata implements Serializable { public static @Nonnull Builder builder() { return new Builder(); } CompletionMetadata(
      Set<String> filterNames,
      Set<NodeInterfacePair> interfaces,
      Map<Ip, IpCompletionMetadata> ips,
      Set<Location> sourceLocations,
      Set<String> mlagIds,
      Map<String, NodeCompletionMetadata> nodes,
      Set<String> prefixes,
      Set<String> routingPolicyNames,
      Set<String> structureNames,
      Set<String> vrfs,
      Set<String> zones); static @Nonnull Builder builder(); @JsonProperty(PROP_FILTER_NAMES) @Nonnull Set<String> getFilterNames(); @JsonProperty(PROP_INTERFACES) @Nonnull Set<NodeInterfacePair> getInterfaces(); @JsonProperty(PROP_IPS) @Nonnull Map<Ip, IpCompletionMetadata> getIps(); @JsonProperty(PROP_SOURCE_LOCATIONS) @Nonnull Set<Location> getSourceLocations(); @JsonProperty(PROP_MLAG_IDS) @Nonnull Set<String> getMlagIds(); @JsonProperty(PROP_NODES) @Nonnull Map<String, NodeCompletionMetadata> getNodes(); @JsonProperty(PROP_PREFIXES) @Nonnull Set<String> getPrefixes(); @JsonProperty(PROP_ROUTING_POLICY_NAMES) @Nonnull Set<String> getRoutingPolicyNames(); @JsonProperty(PROP_STRUCTURE_NAMES) @Nonnull Set<String> getStructureNames(); @JsonProperty(PROP_VRFS) @Nonnull Set<String> getVrfs(); @JsonProperty(PROP_ZONES) @Nonnull Set<String> getZones(); @Override boolean equals(@Nullable Object obj); @Override int hashCode(); @Override String toString(); }
CompletionMetadata implements Serializable { public static @Nonnull Builder builder() { return new Builder(); } CompletionMetadata(
      Set<String> filterNames,
      Set<NodeInterfacePair> interfaces,
      Map<Ip, IpCompletionMetadata> ips,
      Set<Location> sourceLocations,
      Set<String> mlagIds,
      Map<String, NodeCompletionMetadata> nodes,
      Set<String> prefixes,
      Set<String> routingPolicyNames,
      Set<String> structureNames,
      Set<String> vrfs,
      Set<String> zones); static @Nonnull Builder builder(); @JsonProperty(PROP_FILTER_NAMES) @Nonnull Set<String> getFilterNames(); @JsonProperty(PROP_INTERFACES) @Nonnull Set<NodeInterfacePair> getInterfaces(); @JsonProperty(PROP_IPS) @Nonnull Map<Ip, IpCompletionMetadata> getIps(); @JsonProperty(PROP_SOURCE_LOCATIONS) @Nonnull Set<Location> getSourceLocations(); @JsonProperty(PROP_MLAG_IDS) @Nonnull Set<String> getMlagIds(); @JsonProperty(PROP_NODES) @Nonnull Map<String, NodeCompletionMetadata> getNodes(); @JsonProperty(PROP_PREFIXES) @Nonnull Set<String> getPrefixes(); @JsonProperty(PROP_ROUTING_POLICY_NAMES) @Nonnull Set<String> getRoutingPolicyNames(); @JsonProperty(PROP_STRUCTURE_NAMES) @Nonnull Set<String> getStructureNames(); @JsonProperty(PROP_VRFS) @Nonnull Set<String> getVrfs(); @JsonProperty(PROP_ZONES) @Nonnull Set<String> getZones(); @Override boolean equals(@Nullable Object obj); @Override int hashCode(); @Override String toString(); static final CompletionMetadata EMPTY; }