[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[cinvoke-svn] r78 - in trunk/cinvoke/bindings/java: . org/cinvoke
From: |
will |
Subject: |
[cinvoke-svn] r78 - in trunk/cinvoke/bindings/java: . org/cinvoke |
Date: |
7 Jul 2006 11:40:11 -0400 |
Author: will
Date: 2006-07-07 11:40:10 -0400 (Fri, 07 Jul 2006)
New Revision: 78
Modified:
trunk/cinvoke/bindings/java/org/cinvoke/CBThunk.java
trunk/cinvoke/bindings/java/org/cinvoke/CInvProxy.java
trunk/cinvoke/bindings/java/org/cinvoke/CInvoke.java
trunk/cinvoke/bindings/java/org/cinvoke/CInvokeError.java
trunk/cinvoke/bindings/java/org/cinvoke/NativeInt.java
trunk/cinvoke/bindings/java/org/cinvoke/NativeLong.java
trunk/cinvoke/bindings/java/org/cinvoke/NativeLongLong.java
trunk/cinvoke/bindings/java/org/cinvoke/NativeShort.java
trunk/cinvoke/bindings/java/org/cinvoke/Natives.java
trunk/cinvoke/bindings/java/org/cinvoke/Ptr.java
trunk/cinvoke/bindings/java/org_cinvoke_Natives.cpp
Log:
added license text, fixed bug
Modified: trunk/cinvoke/bindings/java/org/cinvoke/CBThunk.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/CBThunk.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/CBThunk.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
class CBThunk {
Modified: trunk/cinvoke/bindings/java/org/cinvoke/CInvProxy.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/CInvProxy.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/CInvProxy.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.lang.reflect.*;
Modified: trunk/cinvoke/bindings/java/org/cinvoke/CInvoke.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/CInvoke.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/CInvoke.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.lang.reflect.*;
Modified: trunk/cinvoke/bindings/java/org/cinvoke/CInvokeError.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/CInvokeError.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/CInvokeError.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
/**
Modified: trunk/cinvoke/bindings/java/org/cinvoke/NativeInt.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/NativeInt.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/NativeInt.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.io.Serializable;
Modified: trunk/cinvoke/bindings/java/org/cinvoke/NativeLong.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/NativeLong.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/NativeLong.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.io.Serializable;
Modified: trunk/cinvoke/bindings/java/org/cinvoke/NativeLongLong.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/NativeLongLong.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/NativeLongLong.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.io.Serializable;
Modified: trunk/cinvoke/bindings/java/org/cinvoke/NativeShort.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/NativeShort.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/NativeShort.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.io.Serializable;
Modified: trunk/cinvoke/bindings/java/org/cinvoke/Natives.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/Natives.java 2006-07-07
05:12:55 UTC (rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/Natives.java 2006-07-07
15:40:10 UTC (rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.util.*;
import java.lang.reflect.*;
@@ -400,48 +428,57 @@
NativeStruct ret = (NativeStruct)_structs.get(cls);
if (ret == null) {
- long st = createStruct(_ctx);
- if (st == 0)
- fail();
- Field[] fields = cls.getFields();
- for (int i = 0; i < fields.length; i++) {
- Class tcls = fields[i].getType();
- if (tcls.isArray()) {
- deleteStruct(_ctx, st);
- throw new CInvokeError(
- "Array structure members not
supported");
- }
- if (tcls.isInterface()) {
- deleteStruct(_ctx, st);
- throw new CInvokeError(
- "Callback structure members not
supported");
- }
- if (tcls.equals(String.class)) {
- deleteStruct(_ctx, st);
- throw new CInvokeError(
- "String structure members not
supported");
- }
- int type = gettypeint(tcls, false);
- if (type == STRUCT_TYPE) {
- if (addStructMemberStruct(_ctx, st,
- fields[i].getName(),
- getNativeStruct(tcls).st) == 0)
{
- try { fail(); }
- finally { deleteStruct(_ctx,
st); }
+ if (_structs.containsKey(cls))
+ throw new CInvokeError(
+ "Structures cannot have themselves as
members");
+ _structs.put(cls, null);
+ try {
+ long st = createStruct(_ctx);
+ if (st == 0)
+ fail();
+ Field[] fields = cls.getFields();
+ for (int i = 0; i < fields.length; i++) {
+ Class tcls = fields[i].getType();
+ if (tcls.isArray()) {
+ deleteStruct(_ctx, st);
+ throw new CInvokeError(
+ "Array structure
members not supported");
}
- } else {
- if (addValueMemberStruct(_ctx, st,
- fields[i].getName(), type) ==
0) {
- try { fail(); }
- finally { deleteStruct(_ctx,
st); }
+ if (tcls.isInterface()) {
+ deleteStruct(_ctx, st);
+ throw new CInvokeError(
+ "Callback structure
members not supported");
}
+ if (tcls.equals(String.class)) {
+ deleteStruct(_ctx, st);
+ throw new CInvokeError(
+ "String structure
members not supported");
+ }
+ int type = gettypeint(tcls, false);
+ if (type == STRUCT_TYPE) {
+ if (addStructMemberStruct(_ctx,
st,
+ fields[i].getName(),
+
getNativeStruct(tcls).st) == 0) {
+ try { fail(); }
+ finally {
deleteStruct(_ctx, st); }
+ }
+ } else {
+ if (addValueMemberStruct(_ctx,
st,
+ fields[i].getName(),
type) == 0) {
+ try { fail(); }
+ finally {
deleteStruct(_ctx, st); }
+ }
+ }
}
+ if (finishStruct(_ctx, st) == 0) {
+ try { fail(); } finally {
deleteStruct(_ctx, st); }
+ }
+ ret = new NativeStruct(_ctx, st);
+ _structs.put(cls, ret);
+ } finally {
+ if (_structs.get(cls) == null)
+ _structs.remove(cls);
}
- if (finishStruct(_ctx, st) == 0) {
- try { fail(); } finally { deleteStruct(_ctx,
st); }
- }
- ret = new NativeStruct(_ctx, st);
- _structs.put(cls, ret);
}
return ret;
Modified: trunk/cinvoke/bindings/java/org/cinvoke/Ptr.java
===================================================================
--- trunk/cinvoke/bindings/java/org/cinvoke/Ptr.java 2006-07-07 05:12:55 UTC
(rev 77)
+++ trunk/cinvoke/bindings/java/org/cinvoke/Ptr.java 2006-07-07 15:40:10 UTC
(rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
package org.cinvoke;
import java.io.Serializable;
Modified: trunk/cinvoke/bindings/java/org_cinvoke_Natives.cpp
===================================================================
--- trunk/cinvoke/bindings/java/org_cinvoke_Natives.cpp 2006-07-07 05:12:55 UTC
(rev 77)
+++ trunk/cinvoke/bindings/java/org_cinvoke_Natives.cpp 2006-07-07 15:40:10 UTC
(rev 78)
@@ -1,3 +1,31 @@
+/*
+C/Invoke Source Code File
+
+Copyright (c) 2006 Will Weisser
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice,
+this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+this list of conditions and the following disclaimer in the documentation
+and/or other materials provided with the distribution.
+ 3. The name of the author may not be used to endorse or promote products
+derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+*/
+
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [cinvoke-svn] r78 - in trunk/cinvoke/bindings/java: . org/cinvoke,
will <=