Package edu.stanford.bmir.protege.web.shared.user

Examples of edu.stanford.bmir.protege.web.shared.user.UserId


        assertEquals(actionA, actionB);
    }

    @Test
    public void hashCodeReturnsSameValueForSameUserId() {
        UserId userId = MockingUtils.mockUserId();
        GetEmailAddressAction actionA = new GetEmailAddressAction(userId);
        GetEmailAddressAction actionB = new GetEmailAddressAction(userId);
        assertEquals(actionA.hashCode(), actionB.hashCode());
    }
View Full Code Here


        assertThat(details.isInTrash(), is(true));
    }

    @Test
    public void builderSetOwnerChangesOwner() {
        UserId userId = mock(UserId.class);
        ProjectDetails details = projectDetails.builder().setOwner(userId).build();
        assertThat(details.getOwner(), is(equalTo(userId)));
    }
View Full Code Here

    @Test
    public void convertShouldReturnSuppliedUserName() {
        UserIdWriteConverter converter = new UserIdWriteConverter();
        String suppliedUserName = "janedoe";
        UserId userId = UserId.getUserId(suppliedUserName);
        String convertedUserName = converter.convert(userId);
        assertEquals(suppliedUserName, convertedUserName);
    }
View Full Code Here

        }
    }


    private void updateProjectPermissions() {
        UserId signedInUser = Application.get().getUserId();
        updatePermissionsForUserId(signedInUser);
        for(UserId userId : user2permissionMap.keySet()) {
            updatePermissionsForUserId(userId);
        }
    }
View Full Code Here

    @Test
    public void convertShouldReturnUserIdWithSuppliedUserName() {
        UserIdReadConverter converter = new UserIdReadConverter();
        String suppliedName = "janedoe";
        UserId UserId = converter.convert(suppliedName);
        assertEquals(suppliedName, UserId.getUserName());
    }
View Full Code Here

                    String description = metadataInterner.intern(metadata.getStringAttribute(DESCRIPTION_META_DATA_ATTRIBUTE, ""));

                    RevisionType type = RevisionType.valueOf(metadata.getStringAttribute(REVISION_TYPE_META_DATA_ATTRIBUTE, RevisionType.EDIT.name()));

                    final UserId userId = UserId.getUserId(userName);
                    final List<OWLOntologyChangeRecord> changeRecords = internChangeRecords(list, axiomInterner, ontologyIDInterner);

                    Revision revision = new Revision(userId, revisionNumber, changeRecords, list.getTimestamp(), description, type);
                    addRevision(revision);
                }
View Full Code Here

TOP

Related Classes of edu.stanford.bmir.protege.web.shared.user.UserId

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.