/*
 * JBoss, Home of Professional Open Source
 * Copyright 2011 Red Hat Inc. and/or its affiliates and other contributors
 * as indicated by the @author tags. All rights reserved.
 * See the copyright.txt in the distribution for a
 * full listing of individual contributors.
 *
 * This copyrighted material is made available to anyone wishing to use,
 * modify, copy, or redistribute it subject to the terms and conditions
 * of the GNU Lesser General Public License, v. 2.1.
 * This program is distributed in the hope that it will be useful, but WITHOUT A
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
 * PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more details.
 * You should have received a copy of the GNU Lesser General Public License,
 * v.2.1 along with this distribution; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
 * MA  02110-1301, USA.
 */

package org.jboss.as.console.client.shared.general.model;

import org.jboss.as.console.client.widgets.forms.Binding;

/**
 * @author Heiko Braun
 * @date 5/17/11
 */
public interface Interface {

    String getName();
    void setName(String name);

    @Binding(detypedName = "any-address")
    boolean isAnyAddress();
    void setAnyAddress(boolean b);

    @Binding(detypedName = "any-ipv4-address")
    boolean isAnyIP6Address();
    void setAnyIP6Address(boolean b);

    @Binding(detypedName = "any-ipv6-address")
    boolean isAnyIP4Address();
    void setAnyIP4Address(boolean b);

    @Binding(expr = true, detypedName = "inet-address")
    String getInetAddress();
    void setInetAddress(String addr);

    @Binding(detypedName = "link-local-address")
    boolean isLinkLocal();
    void setLinkLocal(boolean b);

    @Binding(detypedName = "loopback")
    boolean isLoopback();
    void setLoopback(boolean b);

    @Binding(detypedName = "loopback-address", expr = true)
    String getLoopbackAddress();
    void setLoopbackAddress(String addr);

    boolean isMulticast();
    void setMulticast(boolean b);

    @Binding(expr = true)
    String getNic();
    void setNic(String addr);

    @Binding(expr = true, detypedName = "nic-match")
    String getNicMatch();
    void setNicMatch(String addr);

    @Binding(detypedName = "point-to-point")
    boolean isP2P();
    void setP2P(boolean b);

    @Binding(detypedName = "public-address")
    boolean isPublicAddress();
    void setPublicAddress(boolean b);

    @Binding(detypedName = "site-local-address")
    boolean isSiteLocal();
    void setSiteLocal(boolean b);

    @Binding(expr = true, detypedName = "subnet-match")
    String getSubnetMatch();
    void setSubnetMatch(String addr);

    boolean isUp();
    void setUp(boolean b);

    boolean isVirtual();
    void setVirtual(boolean b);
}

@@ -1018,16 +1018,74 @@
 model;%0A%0A
+import org.jboss.as.console.client.widgets.forms.Address;%0A
 import o
@@ -1134,16 +1134,16 @@
 inding;%0A
-
 %0A/**%0A * 
@@ -1183,16 +1183,43 @@
 /11%0A */%0A
+@Address(%22/interface=%7B0%7D%22)%0A
 public i
@@ -1762,119 +1762,8 @@
 );%0A%0A
-    @Binding(detypedName = %22link-local-address%22)%0A    boolean isLinkLocal();%0A    void setLinkLocal(boolean b);%0A%0A
     
@@ -2308,18 +2308,27 @@
 lean isP
-2P
+ointToPoint
 ();%0A    
@@ -2340,10 +2340,19 @@
 setP
-2P
+ointToPoint
 (boo
@@ -2579,32 +2579,143 @@
 al(boolean b);%0A%0A
+    @Binding(detypedName = %22link-local-address%22)%0A    boolean isLinkLocal();%0A    void setLinkLocal(boolean b);%0A%0A
     @Binding(exp
@@ -2891,24 +2891,24 @@
 sVirtual();%0A
-
     void set
@@ -2927,10 +2927,136 @@
 ean b);%0A
+%0A%0A    // transient%0A%0A    @Binding(skip = true)%0A    String getAddressWildcard();%0A    void setAddressWildcard(String selector);%0A%0A
 %7D%0A

address binding for interface model