Skip to content

Commit

Permalink
Polishing
Browse files Browse the repository at this point in the history
 - Pass attributes into RequestPartFieldsSnippet
 - Add missing package.info.java for new asciidoctor package
  • Loading branch information
wilkinsona committed Oct 25, 2016
1 parent 8035b91 commit 60211da
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/*
* Copyright 2014-2016 the original author or authors.
*
* Licensed 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
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* 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.
*/

/**
* Spring REST Docs Asciidoctor extensions.
*/
package org.springframework.restdocs.asciidoctor;
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ public static RequestPartFieldsSnippet relaxedRequestPartFields(String part,
*/
public static RequestPartFieldsSnippet requestPartFields(String part,
Map<String, Object> attributes, FieldDescriptor... descriptors) {
return requestPartFields(part, Arrays.asList(descriptors));
return requestPartFields(part, attributes, Arrays.asList(descriptors));
}

/**
Expand Down Expand Up @@ -409,7 +409,7 @@ public static RequestPartFieldsSnippet requestPartFields(String part,
*/
public static RequestPartFieldsSnippet requestPartFields(String part,
Map<String, Object> attributes, List<FieldDescriptor> descriptors) {
return new RequestPartFieldsSnippet(part, descriptors);
return new RequestPartFieldsSnippet(part, descriptors, attributes);
}

/**
Expand All @@ -429,7 +429,7 @@ public static RequestPartFieldsSnippet requestPartFields(String part,
*/
public static RequestPartFieldsSnippet relaxedRequestPartFields(String part,
Map<String, Object> attributes, FieldDescriptor... descriptors) {
return relaxedRequestPartFields(part, Arrays.asList(descriptors));
return relaxedRequestPartFields(part, attributes, Arrays.asList(descriptors));
}

/**
Expand All @@ -449,7 +449,7 @@ public static RequestPartFieldsSnippet relaxedRequestPartFields(String part,
*/
public static RequestPartFieldsSnippet relaxedRequestPartFields(String part,
Map<String, Object> attributes, List<FieldDescriptor> descriptors) {
return new RequestPartFieldsSnippet(part, descriptors, true);
return new RequestPartFieldsSnippet(part, descriptors, attributes, true);
}

/**
Expand Down

0 comments on commit 60211da

Please sign in to comment.