![JAR search and dependency download from the Maven repository](/logo.png)
jnr.ffi.provider.jffi.LocalVariableAllocator Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jnr-unixsocket-nodep Show documentation
Show all versions of jnr-unixsocket-nodep Show documentation
com.github.jnr:jnr-unixsocket with orh.objectweb.asm shaded
The newest version!
package jnr.ffi.provider.jffi;
/**
*
*/
class LocalVariableAllocator {
private int nextIndex;
LocalVariableAllocator(SigType[] parameterTypes) {
this.nextIndex = AsmUtil.calculateLocalVariableSpace(parameterTypes) + 1;
}
LocalVariableAllocator(Class... parameterTypes) {
this.nextIndex = AsmUtil.calculateLocalVariableSpace(parameterTypes) + 1;
}
LocalVariableAllocator(int nextIndex) {
this.nextIndex = nextIndex;
}
LocalVariable allocate(Class type) {
LocalVariable var = new LocalVariable(type, nextIndex);
this.nextIndex += AsmUtil.calculateLocalVariableSpace(type);
return var;
}
int getSpaceUsed() {
return nextIndex;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy