@Test void resolveGuest() { UserReference reference = this.resolver.resolve(new DocumentReference("wiki", "space", "XWikiGuest")); assertSame(GuestUserReference.INSTANCE, reference); reference = this.resolver.resolve(new DocumentReference("wiki", "space", "xWiKiGuEsT")); assertSame(GuestUserReference.INSTANCE, reference); }
@Override public UserReference resolve(DocumentReference rawReference, Object... parameters) { UserReference reference; if (rawReference == null) { reference = CurrentUserReference.INSTANCE; } else { reference = resolveName(rawReference.getName()); if (reference == null) { reference = new DocumentUserReference(rawReference, this.entityReferenceProvider); } } return reference; }
DocumentDocumentReferenceUserReferenceResolver extends AbstractUserReferenceResolver<DocumentReference> { @Override public UserReference resolve(DocumentReference rawReference, Object... parameters) { UserReference reference; if (rawReference == null) { reference = CurrentUserReference.INSTANCE; } else { reference = resolveName(rawReference.getName()); if (reference == null) { reference = new DocumentUserReference(rawReference, this.entityReferenceProvider); } } return reference; } }
DocumentDocumentReferenceUserReferenceResolver extends AbstractUserReferenceResolver<DocumentReference> { @Override public UserReference resolve(DocumentReference rawReference, Object... parameters) { UserReference reference; if (rawReference == null) { reference = CurrentUserReference.INSTANCE; } else { reference = resolveName(rawReference.getName()); if (reference == null) { reference = new DocumentUserReference(rawReference, this.entityReferenceProvider); } } return reference; }  }
DocumentDocumentReferenceUserReferenceResolver extends AbstractUserReferenceResolver<DocumentReference> { @Override public UserReference resolve(DocumentReference rawReference, Object... parameters) { UserReference reference; if (rawReference == null) { reference = CurrentUserReference.INSTANCE; } else { reference = resolveName(rawReference.getName()); if (reference == null) { reference = new DocumentUserReference(rawReference, this.entityReferenceProvider); } } return reference; }  @Override UserReference resolve(DocumentReference rawReference, Object... parameters); }
DocumentDocumentReferenceUserReferenceResolver extends AbstractUserReferenceResolver<DocumentReference> { @Override public UserReference resolve(DocumentReference rawReference, Object... parameters) { UserReference reference; if (rawReference == null) { reference = CurrentUserReference.INSTANCE; } else { reference = resolveName(rawReference.getName()); if (reference == null) { reference = new DocumentUserReference(rawReference, this.entityReferenceProvider); } } return reference; }  @Override UserReference resolve(DocumentReference rawReference, Object... parameters);  }