从Java 5开始,Java中引入了枚举类型,expr也可以是enum类型,从Java 7开始,expr还可以是字符串(String),但是长整型(long)在目前所有的版本中都是不可以的。 switch-case语句完全可以与if-else语句互转,但通常来说,switch-case语句执行效率要高。 default在当前switch找不到匹配的case时执行。default并不是必须的。
public String ipPrefix() Get the ipPrefix property: The allocated Prefix. Returns: the ipPrefix value.ipTags public List ipTags() Get the ipTags property: The list of tags associated with the public IP prefix. Returns: the ipTags value.load...
String name() Get the name property: The name of the resource. NatGatewayInner natGateway() Get the natGateway property: NatGateway of Public IP Prefix. Integer prefixLength() Get the prefixLength property: The Length of the Public IP Prefix. ProvisioningState provisioni...
public String toString() Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value. Overrides: toString in class Object Returns: A string representation of this object. See Also: Object.toStr...
public String toString() Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value. Overrides: toString in class Object Returns: A string representation of this object. See Also: Object.toStr...
Stringname() Get the name property: The name of the resource. NatGatewayInnernatGateway() Get the natGateway property: NatGateway of Public IP Prefix. IntegerprefixLength() Get the prefixLength property: The Length of the Public IP Prefix. ...
public String id() Get the id property: Resource ID. Overrides: PublicIpPrefixInner.id() Returns: the id value.ipPrefix public String ipPrefix() Get the ipPrefix property: The allocated Prefix. Returns: the ipPrefix value.ipTags public List ipTags() Get the ipTags property: The list ...
Will be coerced to a String. paramTypes - An array of Class objects identifying the method's formal parameter types, in declared order. Use an empty array if the method has no parameters. Can be null, in which case the method's formal parameter types ...
Will be coerced to a String. paramTypes - An array of Class objects identifying the method's formal parameter types, in declared order. Use an empty array if the method has no parameters. Can be null, in which case the method's formal parameter types ...
{ this.name =name; } } public class Demo1 { public static void main(String[] args){ Dog dog1 = new Dog("xiaohuang"); Dog dog2 = new Dog("xiaohuang"); String s1 = dog1.toString(); String s2 = dog2.toString(); String s3 = "xiaohuang"; String s4 = "xiaohuang"; } } ...