use of php.runtime.annotation.Reflection.Getter in project jphp by jphp-compiler.
the class ODocument method getId.
@Getter
public String getId() {
ORID identity = getWrappedObject().getIdentity();
if (identity.isNew()) {
return null;
}
StringBuilder buffer = new StringBuilder();
return identity.toString(buffer).toString();
}
use of php.runtime.annotation.Reflection.Getter in project jphp by jphp-compiler.
the class PWebRequest method getCookies.
@Getter
public Memory getCookies() {
Cookie[] cookies = getWrappedObject().getCookies();
ArrayMemory result = new ArrayMemory();
if (cookies != null) {
for (Cookie cookie : cookies) {
ArrayMemory item = new ArrayMemory();
item.refOfIndex("name").assign(cookie.getName());
item.refOfIndex("value").assign(cookie.getValue());
item.refOfIndex("path").assign(cookie.getPath());
item.refOfIndex("domain").assign(cookie.getDomain());
item.refOfIndex("maxAge").assign(cookie.getMaxAge());
item.refOfIndex("httpOnly").assign(cookie.isHttpOnly());
item.refOfIndex("secure").assign(cookie.getSecure());
item.refOfIndex("comment").assign(cookie.getComment());
result.add(item);
}
}
return result.toConstant();
}
Aggregations