Skip to content

Commit

Permalink
Fixing three buggy user manual pages
Browse files Browse the repository at this point in the history
git-svn-id: http://umple.googlecode.com/svn/trunk@3072 6ebf9d09-8eb1-0036-9d08-68c07d1b990a
  • Loading branch information
TimLethbridge committed Sep 27, 2013
1 parent 3c8a32d commit ed780e6
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 18 deletions.
33 changes: 17 additions & 16 deletions build/reference/2012SortedAssociations.txt
Expand Up @@ -53,20 +53,20 @@ class Registration {


public String toString() {
return \"Registration: \" getName() \":\" getCode();
return "Registration: " + getName() + ":" + getCode();
}
}

// Mixin with main program and toString method
class Academy {
public static void main(String [ ] args) {
Academy ac = new Academy();
Student j = ac.addRegistrant(12,\"Jim\");
Student a = ac.addRegistrant(4,\"Ali\");
Student m = ac.addRegistrant(8,\"Mary\");
Student f = ac.addRegistrant(3,\"Francois\");
Course c = ac.addCourse(\"CS191\");
Course c2 = ac.addCourse(\"AN234\");
Student j = ac.addRegistrant(12,"Jim");
Student a = ac.addRegistrant(4,"Ali");
Student m = ac.addRegistrant(8,"Mary");
Student f = ac.addRegistrant(3,"Francois");
Course c = ac.addCourse("CS191");
Course c2 = ac.addCourse("AN234");
j.addRegistration(c);
a.addRegistration(c);
m.addRegistration(c);
Expand All @@ -76,13 +76,13 @@ class Academy {
System.out.println(ac);
}
public String toString() {
String result=\"Students:\\n\";
String result="Students:\n";
for (Student s: getRegistrants()) {
result =s \"\\n\";
result +=s + "\n";
}
result =\"Courses:\\n\";
result +="Courses:\n";
for (Course c: getCourses()) {
result =c \"\\n\";
result +=c + "\n";
}

return result;
Expand All @@ -91,19 +91,19 @@ class Academy {

class Student {
public String toString() {
String result=\"Student=\" id \"[\" name \"]\\n\";
String result="Student=" + id + "[" + name + "\n";
for (Registration r: getRegistrations()) {
result =\" In: \" r \"\\n\";
result +=" In: " + r + "\n";
}
return result;
}
}

class Course {
public String toString() {
String result =\"Course=\" code \"\\n\";
String result ="Course=" + code + "\n";
for (Registration r: getRegistrations()) {
result =\" Has: \" r \"\\n\";
result +=" Has: " + r + "\n";
}
return result;
}
Expand All @@ -130,4 +130,5 @@ class Registration
position.association Registration__Student 30,0 44,77;
position.association Course__Registration 110,16 0,29;
position 50 220 109 74;
}@@endexample
}
@@endexample
2 changes: 1 addition & 1 deletion build/reference/3701singleton.txt
Expand Up @@ -5,7 +5,7 @@ noreferences
@@description
<p>Use the Singleton keyword to mark a class as a singleon class. The code ensures that only one object of the class is instantiated at runtime.</p>

<p><a href="http://en.wikipedia.org/wiki/Singleton_pattern" target=wikipedia">For more details on the Singleton pattern, see this Wikipedia page.</a></p>
<p><a href="http://en.wikipedia.org/wiki/Singleton_pattern" target="wikipedia">For more details on the Singleton pattern, see this Wikipedia page.</a></p>

<br />

Expand Down
2 changes: 1 addition & 1 deletion build/reference/3710immutable.txt
Expand Up @@ -11,7 +11,7 @@ noreferences

<p>Individual attributes and associations can be marked as immutable instead of the entire class. An attribute can be marked as <a href="LazyImmutableAttributes.html">lazy immutable</a> if it needs to be initialized after the constructor has finished.</p>

<p><a href="http://en.wikipedia.org/wiki/Immutable_object" target=wikipedia">For more details on the Immutable pattern, see this Wikipedia page.</a></p>
<p><a href="http://en.wikipedia.org/wiki/Immutable_object" target="wikipedia">For more details on the Immutable pattern, see this Wikipedia page.</a></p>

<br />

Expand Down

0 comments on commit ed780e6

Please sign in to comment.