Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Licensed to jclouds, Inc. (jclouds) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. jclouds licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
 package org.jclouds.elb.domain;
 import static;

Adrian Cole
See also:
 public class Policy {
    public static Builder builder() {
       return new Builder();
    public Builder toBuilder() {
       return builder().fromPolicy(this);
    public static class Builder {
       protected String name;
       protected String typeName;
       protected ImmutableMultimap.Builder<StringObjectattributes = ImmutableMultimap.<StringObjectbuilder();

       public Builder name(String name) {
          this. = name;
          return this;

       public Builder typeName(String typeName) {
          this. = typeName;
          return this;

       public Builder attributes(Multimap<StringObjectattributes) {
          return this;

       public Builder attribute(String keyObject value) {
          this..put(checkNotNull(key"key"), checkNotNull(value"value"));
          return this;
       public Policy build() {
          return new Policy(.build());
       public Builder fromPolicy(Policy in) {
    protected final String name;
    protected final String typeName;
    protected final Multimap<StringObjectattributes;
    protected Policy(String nameString typeNameMultimap<StringObjectattributes) {
       this. = checkNotNull(name"name");
       this. = checkNotNull(typeName"typeName");
       this. = ImmutableMultimap.copyOf(checkNotNull(attributes"attributes"));

The name of the policy associated with the LoadBalancer
   public String getName() {
      return ;

The name of the policy type associated with the LoadBalancer.
   public String getTypeName() {
      return ;

A list of policy attribute description structures. Note that values are either Long, Boolean, or String, depending on AttributeMetadata.getType()
   public Multimap<StringObjectgetAttributes() {
      return ;

   public int hashCode() {
      return Objects.hashCode();

   public boolean equals(Object obj) {
      if (this == obj)
         return true;
      if (obj == null)
         return false;
      if (getClass() != obj.getClass())
         return false;
      Policy other = (Policyobj;
      return Objects.equal( && Objects.equal(this.other.typeName);

   public String toString() {
      return Objects.toStringHelper(this).omitNullValues().add("name").add("typeName")
New to GrepCode? Check out our FAQ X