Skip to content

Commit

Permalink
Improving documentation. Related to #20. Closes #14.
Browse files Browse the repository at this point in the history
  • Loading branch information
Rodrigo Alves Vieira committed May 3, 2013
1 parent 1b47cf6 commit a98844d
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 18 deletions.
40 changes: 23 additions & 17 deletions src/java/main/br/ufpe/cin/groundhog/Project.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ public Project(String name, String description) {
this.description = description;
}

/**
* The 3-parameter constructor
* @param name the project name
* @param description the project description
* @param iconURL the project's icon URL
*/
public Project(String name, String description, String iconURL) {
this(name, description);
this.iconURL = iconURL;
Expand Down Expand Up @@ -215,56 +221,56 @@ public int getFollowersCount() {
}

/**
*
* @param followersCount an integer for setting the number of people following the project on its forge
* Sets how many followers the project has on its forge
* @param followersCount an integer, the number of people following the project
*/
public void setFollowersCount(int followersCount) {
this.followersCount = followersCount;
}

/**
*
* @return an integer correspondent to the number of forks the project in question has
* Informs the number of forks the project has
* @return an integer correspondent to the number of forks
*/
public int getForksCount() {
return this.forksCount;
}

/**
*
* An indicator of how many times the project has been forked.
* @param forksCount an integer for setting the number of forks the project has.
* In order words, an indicator of how many times the project has been forked.
*/
public void setForksCount(int forksCount) {
this.forksCount = forksCount;
}

/**
*
* @return an integer correspondent to the number of open issues of the project
* Informs the number of open issues of the project
* @return an integer value correspondent to the amount of open issues
*/
public int getIssuesCount() {
return this.issuesCount;
}

/**
*
* Sets the number of issues of a project
* @param issuesCount an integer for setting the number of Issues of the project
*/
public void setIssuesCount(int issuesCount) {
this.issuesCount = issuesCount;
}

/**
*
* @return a boolean value informing whether the project is a fork of another or not
* Tells whether a project is a fork of another or not
* @return a boolean value: true if it's a fork, false otherwise
*/
public boolean isFork() {
return this.isFork;
}

/**
*
* Sets if the project is a fork of another or not
* @param value a boolean value for informing whether the project is a fork of another or not
*/
public void setIsFork(boolean value) {
Expand All @@ -279,15 +285,15 @@ public void setIsFork(boolean value) {
*/

/**
*
* @return the creation date of the project in question
* Informs the creation date of the project
* @return a Date object correspondent to the project's creation date
*/
public Date getCreatedAt() {
return this.createdAt;
}

/**
*
* Sets the creation date of the project
* @param createdAt a Date object for setting the creation date of the project
*/
public void setCreatedAt(Date createdAt) {
Expand All @@ -307,15 +313,15 @@ public void setCreatedAt(String createdAtParam) throws java.text.ParseException
}

/**
*
* @return the date of the latest push to the project in question
* Returns the date of the latest push to the project
* @return a Date object of the latest push
*/
public Date getLastPushedAt() {
return this.lastPushedAt;
}

/**
*
* Sets the date on which the last push has been submitted to the project's source code
* @param lastPushedAtParam the Date object correspondent to the date of the last push to the project
* in question
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,12 @@ private static File createFile(FileHeader fh, File destination) {
private static File makeFile(File destination, String name)
throws IOException {
String[] dirs = name.split("\\\\");
String path = "";

if (dirs == null) {
return null;
}
String path = "";

int size = dirs.length;
if (size == 1) {
return new File(destination, name);
Expand Down

0 comments on commit a98844d

Please sign in to comment.