use of php.runtime.memory.StringMemory in project jphp by jphp-compiler.
the class ReflectionParameter method setEntity.
public void setEntity(ParameterEntity entity) {
this.entity = entity;
getProperties().put("name", new StringMemory(entity.getName()));
}
use of php.runtime.memory.StringMemory in project jphp by jphp-compiler.
the class ReflectionProperty method setEntity.
public void setEntity(PropertyEntity entity) {
this.entity = entity;
getProperties().put("name", new StringMemory(entity.getName()));
getProperties().put("class", new StringMemory(entity.getClazz().getName()));
}
use of php.runtime.memory.StringMemory in project jphp by jphp-compiler.
the class JavaException method setThrowable.
public void setThrowable(Throwable throwable) {
this.throwable = throwable;
clazz.setProperty(this, "message", new StringMemory(throwable.toString()));
}
use of php.runtime.memory.StringMemory in project jphp by jphp-compiler.
the class Reflection method exception.
protected final void exception(Environment env, String message, Object... args) {
ReflectionException e = new ReflectionException(env);
e.__construct(env, new StringMemory(String.format(message, args)));
env.__throwException(e, false);
}
use of php.runtime.memory.StringMemory in project jphp by jphp-compiler.
the class BaseBaseException method getTraceAsString.
@Signature
public Memory getTraceAsString(Environment env, Memory... args) {
int i = 0;
StringBuilder sb = new StringBuilder();
if (callStack != null) {
for (CallStackItem e : getCallStack()) {
if (i != 0)
sb.append("\n");
sb.append("#").append(i).append(" ").append(e.toString(false));
i++;
}
if (i != 0)
sb.append("\n");
sb.append("#").append(i).append(" {main}");
}
return new StringMemory(sb.toString());
}
Aggregations