I'm trying to print out the details from the subclass auctionsale but I'm getting:
Exception in thread "main" java.lang.ClassCastException: SuperClass cannot be cast to Subclass the subclass extends...
Type: Posts; User: Gerardgrundy
I'm trying to print out the details from the subclass auctionsale but I'm getting:
Exception in thread "main" java.lang.ClassCastException: SuperClass cannot be cast to Subclass the subclass extends...
I've managed to figure this out but I can't post the code because its for an assignment.
Thanks for your help.
I'm in that tapatalk app can you do that in it I can't seem to find it.
It's just that this is for an assignment and I can't really show the code. I wonder if making a variation of the code would be ok?
I've had to delete a hidden file so that I can get the functionality back on command c. Yay got it working again. It'll be the last time I do that.
The variables I have declare but they are in another class.
They are private and then I've used getters and setters to access them then I created a method that gets a result from the variables. But...
Yes I've tried that.
Regards Gerard
Hi,
I'm not sure at all how to start this class of?
I've been told I need to declare and instantiate the array as a static member at the class level.
I have no idea what this means?
Also I...
Hi,
I have made a short cut key in eclipse to open a new java class with command + C though this is also the quick key for copy.
I have tried restoring the quick keys back to default .
I have...
The method has to return true false.
Then that is to be checked and if true print Yes if false no.
Hi,
I'm trying to do a boolean method
public boolean x()
{
if (y() >= z)
{
return true;
}
public class a
{
private String b;
private String c
// this is what I indented is this better?
public a(String b, String c)
// do i need these curly braces below. why do i need...
public class a
{
private String b;
// this is what I indented is this better?
public a(String b)
{
}
public String getb()
{
Thanks for your quick reply. I gave the alt-s f a go and nothing happens. I've got some custom formatting set up with this quick key. Should the constructor be indented 4 spaces with the rest of the...
Hi I'm doing some code and the use of the Curley braces is confusing me.
public class a
{
private String b;
public a(String b)
{
}