Code Comments
Programming Forum and web based access to our favorite programming groups.Hi,
In Java,Is it possible to use array tpe with in Record type?
Record Type:
{Variable=String;Variable=long}
like this
{Variable=int[];Variable=long[]}
Is this possible?
Post Follow-up to this message"priya" <priya11.karthik@gmail.com> schreef in bericht
news:1117870563.829182.42550@g43g2000cwa.googlegroups.com...
> Hi,
> In Java,Is it possible to use array tpe with in Record type?
What is a Record type?
> Record Type:
>
> {Variable=String;Variable=long}
>
> like this
>
> {Variable=int[];Variable=long[]}
>
> Is this possible?
What you just wrote is not Java.
Post Follow-up to this messageOn Sat, 4 Jun 2005 14:10:44 +0200, "Boudewijn Dijkstra"
<usenet@bdijkstra.tmfweb.nl> wrote:
>"priya" <priya11.karthik@gmail.com> schreef in bericht
>news:1117870563.829182.42550@g43g2000cwa.googlegroups.com...
>
>What is a Record type?
Java doesn't have Record Types. In C/C++/Pascal[1] they are
datastructures that contain just data (as opposed to data + methods as
Objects).
>
>What you just wrote is not Java.
Nope it is not. What I think the OP was trying to do was this:
class MyClass {
int[] intArray;
long[] longArray;
}
Maybe? Hard to tell as the OP didn't make much sense
--
now with more cowbell
Post Follow-up to this message
Show a Printable Version
Email This Page to Someone!
Receive updates to this thread
Powered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.