Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

NX:about the DBAccess interface

 
janvy wei
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,all
my assignment is B&C constractor,and i have a question about the
instructions. thanks in advance
in the required interface section,it says:
"Your data access class must be called "Data.java", must be in a package called "suncertify.db", and must implement the following interface DBAccess",
but,whether my implementation could only throw a unchecked exception--OperationNotSupport in some method i don't need for example--deleteRecord(long recNo, long lockCookie)?
 
George Marinkovich
Ranch Hand
Posts: 619
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Janvy,
Originally posted by janvy wei:
"Your data access class must be called "Data.java", must be in a package called "suncertify.db", and must implement the following interface DBAccess",
but,whether my implementation could only throw a unchecked exception--OperationNotSupport in some method i don't need for example--deleteRecord(long recNo, long lockCookie)?

I guess that depends on what your definition of the word "implement" is. Oops, I think that dodge only works if you're a former president of the United States from Arkansas. Since he's supposed to be writing his memoirs rather than working on the SCJD, I'll assume that you're not him and try to give a straight answer to your query.
Most people in the forum I believe have made the assumption that implement means implement according to the method comments provided in the DBAccess interface. While you can argue that what you are proposing is technically an implementation of the deleteRecord method, it really doesn't do what the method comment claims it should, does it? Unfortunately, I think you're on the hook for fully implementing every method specified in the DBAccess interface if you want to claim that you're implementing the DBAccess interface as the assignment instructions seem to require.
Alternatively, you could provide trivial implementations of all the DBAccess methods that are not used by your client and see what happens. Personally, I didn't want to gamble with the 40 possible points for the Data class, so I implemented everything.
Hope this helps,
George
 
janvy wei
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
george,thanks for your help.
and have you completed your submission?
 
George Marinkovich
Ranch Hand
Posts: 619
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, it's been submitted for nearly a month now...
 
janvy wei
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
george,congratulations!
Would you mind sharing your point total broken down by category?
 
George Marinkovich
Ranch Hand
Posts: 619
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Janvy,
I hope your congratulations isn't premature.
Originally posted by janvy wei:
Would you mind sharing your point total broken down by category?

I plan to do so. But it will be posted in the Certification Results forum rather than here. It's well worth checking that forum occasionally as you can see what scores people have been receiving, and often the people are willing to discuss aspects of their design and point out areas where they may have made mistakes.
Hope this helps,
George
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic