Skip to content

Commit

Permalink
feat(page): add PageType to Page model
Browse files Browse the repository at this point in the history
this commit add a PageType enum containing supported type for writing
documentations like MD, SWAGGER, etc

Breaking changes:
- type attribute in Page.java is now of type PageType
  • Loading branch information
M3lkior committed Jan 26, 2016
1 parent 0cecede commit 72c3079
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public class Page {

private String name;

private String type;
private PageType type;

private String content;

Expand All @@ -57,7 +57,7 @@ public void setId(String id) {
this.id = id;
}

public String getType() {
public PageType getType() {
return type;
}

Expand All @@ -69,7 +69,7 @@ public void setName(String name) {
this.name = name;
}

public void setType(String type) {
public void setType(PageType type) {
this.type = type;
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package io.gravitee.repository.management.model;

/**
* @author Ludovic Dussart (ludovic.dussart at gmail.com)
* Managed types for page documentation
*
*/
public enum PageType {

MARKDOWN,
RAML,
SWAGGER

}

0 comments on commit 72c3079

Please sign in to comment.