Dave's Brain

Browse - Programming Tips - How can I do a C/C++ style void * in Java?

Date: 2012feb28
Language: Java

Q.  How can I do a C/C++ style void * in Java?

A.  Use Object to pass a generic blob.

In C/C++:

myfunc(void *userdata);
In Java:
myfunc(Object userdata);

Add a comment

Sign in to add a comment
Copyright © 2008-2017, dave - Code samples on Dave's Brain is licensed under the Creative Commons Attribution 2.5 License. However other material, including English text has all rights reserved.