summaryrefslogtreecommitdiff
path: root/java/demo/Freeze/library/BookI.java
diff options
context:
space:
mode:
authorMichi Henning <michi@zeroc.com>2002-07-25 07:04:46 +0000
committerMichi Henning <michi@zeroc.com>2002-07-25 07:04:46 +0000
commit9e9f73e98a399180afc1a618bd4cba534fa5ed7b (patch)
tree87ab44e1284c95a9f129a7536225c6b4df79de65 /java/demo/Freeze/library/BookI.java
parentFixes (diff)
downloadice-9e9f73e98a399180afc1a618bd4cba534fa5ed7b.tar.bz2
ice-9e9f73e98a399180afc1a618bd4cba534fa5ed7b.tar.xz
ice-9e9f73e98a399180afc1a618bd4cba534fa5ed7b.zip
Changed Slice parser to disallow leading underscore for identifiers.
Changed Slice parser to reject identifiers beginning with "Ice", unless the --ice option is used. Changed Slice parser to disallow identifiers that have a trailing "Operations", "Holder", "Helper", "Prx", or "Ptr", to avoid clashes with language mappings. Fixed tests and remaining code base to work correctly with the changed rules.
Diffstat (limited to 'java/demo/Freeze/library/BookI.java')
-rw-r--r--java/demo/Freeze/library/BookI.java18
1 files changed, 9 insertions, 9 deletions
diff --git a/java/demo/Freeze/library/BookI.java b/java/demo/Freeze/library/BookI.java
index aa1c56994c6..8cc4622c9a7 100644
--- a/java/demo/Freeze/library/BookI.java
+++ b/java/demo/Freeze/library/BookI.java
@@ -21,40 +21,40 @@ class BookI extends Book
//
// Immutable.
//
- return _description;
+ return description;
}
synchronized public String
getRenterName(Ice.Current current)
throws BookNotRentedException
{
- if(_rentalCustomerName.length() == 0)
+ if(rentalCustomerName.length() == 0)
{
throw new BookNotRentedException();
}
- return _rentalCustomerName;
+ return rentalCustomerName;
}
synchronized public void
rentBook(String name, Ice.Current current)
throws BookRentedException
{
- if(_rentalCustomerName.length() != 0)
+ if(rentalCustomerName.length() != 0)
{
throw new BookRentedException();
}
- _rentalCustomerName = name;
+ rentalCustomerName = name;
}
synchronized public void
returnBook(Ice.Current current)
throws BookNotRentedException
{
- if(_rentalCustomerName.length() == 0)
+ if(rentalCustomerName.length() == 0)
{
throw new BookNotRentedException();
}
- _rentalCustomerName = new String();;
+ rentalCustomerName = new String();;
}
synchronized public void
@@ -63,7 +63,7 @@ class BookI extends Book
{
try
{
- _library.remove(_description);
+ _library.remove(description);
}
catch(Freeze.DBNotFoundException ex)
{
@@ -88,7 +88,7 @@ class BookI extends Book
// new creation of a book, and the other for restoring a
// previously saved book).
//
- _rentalCustomerName = new String();
+ rentalCustomerName = new String();
}
private LibraryI _library;