wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes arraycopy Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "arraycopy" Watch "arraycopy" New topic
Author

arraycopy

Struan Kay
Greenhorn

Joined: May 20, 2004
Posts: 3
This is probably just a 'because it is.' type question but is there any reason why the arraycopy method is in the java.lang.System class not java.util.Arrays and why isn't the c uppercase?

Thanks

Struan
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

Stuff in the java.lang.System class is pretty much the first defined in Java, and it predates java.lang.Arrays. I think because it came out first it is now pretty fundamental to so many Java programs that there is little chance for Sun to deprecate it.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
So, if you were curious if there existed some well thought out design considerations behind this situation, the answer is, "Probably not."


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
...and why isn't the c uppercase?

There may well exist some "historic" reason for it (e.g. something in the C or C++ programming language standard library with the same name and a similar function), but I'm not aware of such a thing.

I'd guess that someone just wasn't following the current naming conventions, and then it was too late to change, without affecting substantial existing code.
[ May 27, 2004: Message edited by: Dirk Schreckmann ]
Jeroen Wenting
Ranch Hand

Joined: Oct 12, 2000
Posts: 5093
or maybe they wanted to have some exceptions to the rule to make the certification exam more "interesting"


42
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: arraycopy
 
Similar Threads
array copy
array doubt
i can't find some more detailed source code ?
why can't my arraycopy work???
Java array help