org.jclouds.s3.predicates.validators
Class BucketNameValidator
java.lang.Object
org.jclouds.predicates.Validator<String>
org.jclouds.predicates.validators.DnsNameValidator
org.jclouds.s3.predicates.validators.BucketNameValidator
- All Implemented Interfaces:
- com.google.common.base.Predicate<String>
public class BucketNameValidator
- extends DnsNameValidator
Validates name for S3 buckets. The complete requirements are listed at:
http://docs.amazonwebservices.com/AmazonS3/latest/index.html?BucketRestrictions.html
- Author:
- Adrian Cole
- See Also:
InputParamValidator
,
Validator
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.google.common.base.Predicate |
equals |
validate
public void validate(String containerName)
- Description copied from class:
Validator
- Validates the parameter
- Overrides:
validate
in class DnsNameValidator
- Parameters:
containerName
- parameter to be validated
exception
protected IllegalArgumentException exception(String containerName,
String reason)
- Overrides:
exception
in class DnsNameValidator
getAcceptableRange
protected com.google.common.base.CharMatcher getAcceptableRange()
- Amazon also permits periods in the dns name.
It also permits underscores, although they aren't recommended.
- Overrides:
getAcceptableRange
in class DnsNameValidator
Copyright © 2009-2012 jclouds. All Rights Reserved.