Emanuel Greisen wrote:
I am currently trying to do a rename since I have some overloaded C++
functions.
Here is my renames:
...
130 // RENAMING OF CONST-VARIANTS
131 %rename(getMaterialConst) *::getMaterial() const;
132 %rename(getBoundingBoxConst) getBoundingBox() const;
133 //%ignore getBoundingBox() const;
134 %rename(getVerticesConst) *::getVertices() const;
135 %rename(getIndicesConst) *::getIndices() const;
136 %rename(getLastConst) *::getLast() const;
...
I am not getting warnings about ignored methods (did before I inserted
the %rename lines)
But.... I get java compile errors about the methods being duplicated.
...
src/java/net/sf/jirr/SMeshBuffer.java:92: getMaterial() is already
defined in net.sf.jirr.SMeshBuffer
public SMaterial getMaterial() {
^
src/java/net/sf/jirr/SMeshBuffer.java:101: getVertices() is already
defined in net.sf.jirr.SMeshBuffer
public SWIGTYPE_p_irr__core__arrayTirr__video__S3DVertex_t
getVertices() {
^
src/java/net/sf/jirr/SMeshBuffer.java:110: getIndices() is already
defined in net.sf.jirr.SMeshBuffer
public SWIGTYPE_p_irr__core__arrayTunsigned_short_t getIndices() {
^
src/java/net/sf/jirr/SMeshBuffer.java:119: getBoundingBox() is already
defined in net.sf.jirr.SMeshBuffer
public aabbox3df getBoundingBox() {
^
src/java/net/sf/jirr/ILogger.java:56:
log(java.lang.String,java.lang.String,net.sf.jirr.ELOG_LEVEL) is already
defined in net.sf.jirr.ILogger
public void log(String text, String hint, ELOG_LEVEL ll) {
^
src/java/net/sf/jirr/ILogger.java:60:
log(java.lang.String,net.sf.jirr.ELOG_LEVEL) is already defined in
net.sf.jirr.ILogger
public void log(String text, ELOG_LEVEL ll) {
^
src/java/net/sf/jirr/SMesh.java:82: getBoundingBox() is already defined
in net.sf.jirr.SMesh
public aabbox3df getBoundingBox() {
^
src/java/net/sf/jirr/SMeshBufferLightMap.java:92: getMaterial() is
already defined in net.sf.jirr.SMeshBufferLightMap
public SMaterial getMaterial() {
^
src/java/net/sf/jirr/SMeshBufferLightMap.java:101: getVertices() is
already defined in net.sf.jirr.SMeshBufferLightMap
public SWIGTYPE_p_irr__core__arrayTirr__video__S3DVertex2TCoords_t
getVertices() {
^
src/java/net/sf/jirr/SMeshBufferLightMap.java:110: getIndices() is
already defined in net.sf.jirr.SMeshBufferLightMap
public SWIGTYPE_p_irr__core__arrayTunsigned_short_t getIndices() {
^
src/java/net/sf/jirr/SMeshBufferLightMap.java:119: getBoundingBox() is
already defined in net.sf.jirr.SMeshBufferLightMap
public aabbox3df getBoundingBox() {
...
Just for reference, here is some of the C++ source I am trying to SWIG !
...
//! returns pointer to vertex data. The data is a array of vertices. Which
vertex
//! type is used can be determinated with getVertexType().
virtual const void* getVertices() const = 0;
//! returns pointer to vertex data. The data is a array of vertices. Which
vertex
//! type is used can be determinated with getVertexType().
virtual void* getVertices() = 0;
...
Strange. Are you sure you are compiling the last Java files that SWIG generated?
Break it into a small example for us to look at if it really is misbehaving. BTW
the warning messages will disappear once you've renamed the offending method as
it will no longer be ignored but generated under the new name.
William
_______________________________________________
Swig maillist - Swig@xxxxxxxxxxxxxxx
http://mailman.cs.uchicago.edu/mailman/listinfo/swig