> @@ -56,20 +62,32 @@ public Builder versions(Iterable<Version> versions) {
> return this;
> }
>
> + public Builder from(CookbookDefinition def) {
> + this.url = def.getUrl();
> + this.versions.addAll(def.getVersions());
Just set the name as you set the other properties. If the parameter comes with
the name populated, just set it.
You don't know if the name is available or not (you don't know where the
parameter comes from, people could use this builder method in their app to
convert the CookbookDefinition to a mutable object to be able to modify it, for
example).
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/24/files#r6430706