rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { | final JabberId userId, final UUID uniqueId, final Long versionId) { | public List<DocumentVersion> readArchiveDocumentVersions( final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { synchronized (getImplLock()) { return getImpl().readArchiveDocumentVersions(userId, uniqueId, versionI... |
final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { | final JabberId userId, final UUID uniqueId, final Long versionId) { | public List<DocumentVersion> readBackupDocumentVersions( final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { synchronized (getImplLock()) { return getImpl().readBackupDocumentVersions(userId, uniqueId, versionId,... |
versionId, documentUniqueId); | versionId); | public List<DocumentVersion> readBackupDocumentVersions( final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { synchronized (getImplLock()) { return getImpl().readBackupDocumentVersions(userId, uniqueId, versionId,... |
public void removeTeamMember(final UUID uniqueId, final JabberId jabberId) { synchronized(getImplLock()) { getImpl().removeTeamMember(uniqueId, jabberId); | public void removeTeamMember(final UUID uniqueId, final List<JabberId> team, final JabberId jabberId) { synchronized (getImplLock()) { getImpl().removeTeamMember(uniqueId, team, jabberId); | public void removeTeamMember(final UUID uniqueId, final JabberId jabberId) { synchronized(getImplLock()) { getImpl().removeTeamMember(uniqueId, jabberId); } } |
writeKeyHolder(document, writer); | public void marshal(Object source, HierarchicalStreamWriter writer, MarshallingContext context) { logger.info("marshal(Object, HierarchicalStreamWriter)"); logger.debug(source); final Document document = (Document) source; writeName(document.getName(), writer); writeCreatedBy(document.getCreatedBy(), writer); ... | |
writeKeyHolder(document, writer); | void marshalForVersion(final DocumentVersion version, final Document document, final HierarchicalStreamWriter writer, final MarshallingContext context) { logger.info("marshal(Object, HierarchicalStreamWriter)"); logger.debug(document); writeName(document.getName(), writer); writeCreatedBy(document.getCreatedBy... | |
Boolean isComplete = Boolean.FALSE; while (Boolean.FALSE == isComplete) { | boolean isComplete = false; while (false == isComplete) { | public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandlePublishedIQ query = new HandlePublishedIQ(); Boolean isComplete = Boolean.FALSE; while (Boolean.FALSE == isComplete) { if (isStartTa... |
isComplete = Boolean.TRUE; | isComplete = true; | public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandlePublishedIQ query = new HandlePublishedIQ(); Boolean isComplete = Boolean.FALSE; while (Boolean.FALSE == isComplete) { if (isStartTa... |
Boolean isComplete = Boolean.FALSE; while(Boolean.FALSE == isComplete) { | boolean isComplete = false; while(false == isComplete) { | public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandleArtifactPublishedIQ query = new HandleArtifactPublishedIQ(); Boolean isComplete = Boolean.FALSE; while(Boolean.FALSE == isComplete) { ... |
isComplete = Boolean.TRUE; | isComplete = true; | public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandleArtifactPublishedIQ query = new HandleArtifactPublishedIQ(); Boolean isComplete = Boolean.FALSE; while(Boolean.FALSE == isComplete) { ... |
Class objectClass = Class.forName(this.className); } catch (ClassNotFoundException e) { throw new JcrMappingException("Class not found : " + className); | ReflectionUtils.forName(this.className); } catch (JcrMappingException e) { throw new JcrMappingException("Class used in descriptor not found : " + className); | private void validateClassName() { try { Class objectClass = Class.forName(this.className); } catch (ClassNotFoundException e) { throw new JcrMappingException("Class not found : " + className); } } |
String t = "iceland"; Analysis a = doAnalysis(s, t); | Analysis a = doAnalysis(s, topicString); | private void handleIncomingStory(Message msg) { Story s = Story.createFromYAML(msg.content); String t = "iceland"; Analysis a = doAnalysis(s, t); if (a.isRelevant()) { Message m = new Message(); m.to = "WB.Analyses"; m.content = a.toYAML(); ... |
protected static void assertNotNull(final String assertion, final Collection<DocumentVersion> versions) { assertNotNull(assertion + " [DOCUMENT VERSIONS IS NULL]", (Object) versions); for(final DocumentVersion version : versions) { assertNotNull(assertion, version); } | protected static void assertNotNull(final String assertion, final ArtifactReceipt receipt) { assertNotNull(assertion + " [RECEIPT IS NULL]", (Object) receipt); assertNotNull(assertion + " [RECEIPT'S ARTIFACT ID IS NULL]", receipt.getArtifactId()); assertNotNull(assertion + " [RECEIPT'S USER ID IS NULL]", receipt.getUse... | protected static void assertNotNull(final String assertion, final Collection<DocumentVersion> versions) { assertNotNull(assertion + " [DOCUMENT VERSIONS IS NULL]", (Object) versions); for(final DocumentVersion version : versions) { assertNotNull(assertion, version); } } |
return handleDocumentSent(event.getPublishedBy(), event.getPublishedOn(), event.getArtifactUniqueId(), event.getArtifactVersionId(), event.getArtifactName(), event.getArtifactChecksum(), event.getArtifactStreamId()); | try { final File streamFile = downloadStream(event.getArtifactStreamId()); final InternalArtifactModel artifactModel = getArtifactModel(); final Document document; final DocumentVersion version; if (artifactModel.doesExist(event.getArtifactUniqueId())) { logger.logWarning("Document {0} already exists.", event.getArtif... | DocumentVersion handleDocumentPublished( final ContainerArtifactPublishedEvent event) { logger.logApiId(); logger.logVariable("event", event); return handleDocumentSent(event.getPublishedBy(), event.getPublishedOn(), event.getArtifactUniqueId(), event.ge... |
final InternalArtifactModel artifactModel = getInternalArtifactModel(); | final InternalArtifactModel artifactModel = getArtifactModel(); | Boolean isDraftModified(final Long documentId) { logger.logApiId(); logger.logVariable("documentId", documentId); try { final InternalArtifactModel artifactModel = getInternalArtifactModel(); if (artifactModel.doesVersionExist(documentId, Versioning.START)) { final Documen... |
this.logger = new Log4JWrapper(); | this.logger = new Log4JWrapper(StackUtil.getCallerClassName()); | protected AbstractModelImpl(final Environment environment, final Workspace workspace) { super(); this.environment = environment; this.internalModelFactory = new InternalModelFactory(getContext(), environment, workspace); this.l18n = new Localization(LocalizationContext.MODEL);... |
public void addListener(final ArtifactListener listener); | public <T extends XMPPEvent> void addListener(final Class<T> eventClass, final XMPPEventListener<T> listener); | public void addListener(final ArtifactListener listener); |
public void removeListener(final ArtifactListener listener); | public void removeListener(final SessionListener listener); | public void removeListener(final ArtifactListener listener); |
final JabberId deniedBy) throws ParityException { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); | final JabberId deniedBy) throws ParityException, SmackException { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); final Document document = iDModel.get(artifactUniqueId); | static void notifyKeyRequestDenied(final UUID artifactUniqueId, final JabberId deniedBy) throws ParityException { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.FALSE, deniedBy)... |
final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } final InternalArtifactModel iAModel = ArtifactModel.getInternalModel(sContext); iAModel.auditKeyRequestDenied(document.getId(), loggedInUser.getId(), currentDateTime(), deniedBy); | static void notifyKeyRequestDenied(final UUID artifactUniqueId, final JabberId deniedBy) throws ParityException { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.FALSE, deniedBy)... | |
auditor.keyResponseDenied(documentId, xmppHelper.getUser().getId(), currentDateTime(), requestedBy); | void sendKeyResponse(final Long documentId, final JabberId requestedBy, final KeyResponse keyResponse) throws ParityException { logger.info("sendKeyResponse(UUID,User,KeyResponse)"); logger.debug(documentId); logger.debug(requestedBy); logger.debug(keyResponse); assertLoggedInUserIsKeyHolder(documentId); synch... | |
ArtifactIOHandler() { super(); } | public ArtifactIOHandler() { super(); } | ArtifactIOHandler() { super(); } |
List<ArtifactFlag> getFlags(final Long artifactId) | public List<ArtifactFlag> getFlags(final Long artifactId) | List<ArtifactFlag> getFlags(final Long artifactId) throws HypersonicException { final Session session = openSession(); try { return getFlags(session, artifactId); } finally { session.close(); } } |
if (info instanceof DataInfo) | if (validateToolInfo(info)) | public void addTool(ToolInfo info) { if (info instanceof DataInfo) { //add static data to the appTools map appTools.put(info.getKey(), info.getInstance(null)); } else if (info instanceof ServletToolInfo) { ServletToolInfo sti = (ServletToolInfo)... |
appTools.put(info.getKey(), info.getInstance(null)); } else if (info instanceof ServletToolInfo) { ServletToolInfo sti = (ServletToolInfo)info; if (ViewContext.REQUEST.equalsIgnoreCase(sti.getScope())) | if (info instanceof ServletToolInfo) | public void addTool(ToolInfo info) { if (info instanceof DataInfo) { //add static data to the appTools map appTools.put(info.getKey(), info.getInstance(null)); } else if (info instanceof ServletToolInfo) { ServletToolInfo sti = (ServletToolInfo)... |
requestToolInfo.add(sti); } else if (ViewContext.SESSION.equalsIgnoreCase(sti.getScope())) { sessionToolInfo.add(sti); } else if (ViewContext.APPLICATION.equalsIgnoreCase(sti.getScope())) { appTools.put(sti.getKey(), sti.getInstance(servletContext)); | ServletToolInfo sti = (ServletToolInfo)info; if (ViewContext.REQUEST.equalsIgnoreCase(sti.getScope())) { requestToolInfo.add(sti); return; } else if (ViewContext.SESSION.equalsIgnoreCase(sti.getScope())) { sessionToolInfo.add(sti); return; } else if (ViewContext.APPLICATION.equalsIgnoreCase(sti.getScope())) { appTool... | public void addTool(ToolInfo info) { if (info instanceof DataInfo) { //add static data to the appTools map appTools.put(info.getKey(), info.getInstance(null)); } else if (info instanceof ServletToolInfo) { ServletToolInfo sti = (ServletToolInfo)... |
LOG.warn("Unknown scope '" + sti.getScope() + "' - " + sti.getKey() + " will be request scoped."); requestToolInfo.add(sti); | requestToolInfo.add(info); | public void addTool(ToolInfo info) { if (info instanceof DataInfo) { //add static data to the appTools map appTools.put(info.getKey(), info.getInstance(null)); } else if (info instanceof ServletToolInfo) { ServletToolInfo sti = (ServletToolInfo)... |
else { requestToolInfo.add(info); } | public void addTool(ToolInfo info) { if (info instanceof DataInfo) { //add static data to the appTools map appTools.put(info.getKey(), info.getInstance(null)); } else if (info instanceof ServletToolInfo) { ServletToolInfo sti = (ServletToolInfo)... | |
new NativeSkin().roundCorners(this); | public void setVisible(boolean b) { if (b) { setLocation(calculateLocation()); new NativeSkin().roundCorners(this); } super.setVisible(b); } | |
synchronized(this) { notifyAll(); | synchronized (OpheliaJFrame.this) { OpheliaJFrame.this.notifyAll(); | public void windowClosed(final WindowEvent e) { synchronized(this) { notifyAll(); } } |
public void documentReactivated(DocumentEvent e) { if(e.isRemote()) systemApplication.fireDocumentReactivated(e.getUser(), e.getDocument(), e.getDocumentVersion()); } | private DocumentListener createDocumentListener() { return new DocumentAdapter() { public void documentClosed(final DocumentEvent e) { if(e.isRemote()) systemApplication.fireDocumentClosed(e.getDocument()); } public void documentCreated(final Document... | |
writeKeyHolder(project, writer); | public void marshal(Object source, HierarchicalStreamWriter writer, MarshallingContext context) { final Project project = (Project) source; writeName(project.getName(), writer); writeCreatedBy(project.getCreatedBy(), writer); writeKeyHolder(project, writer); writeId(project.getId(), writer); writeCreatedOn(pro... | |
final Document document, final CloseEvent closeEvent) { | final Document document, final CloseEvent closeEvent, final Map<JabberId, User> closeEventUsers) { | private static CloseHistoryItem buildCloseHistoryItem( final Document document, final CloseEvent closeEvent) { final CloseHistoryItem closeHistoryItem = new CloseHistoryItem(); closeHistoryItem.setDate(closeEvent.getCreatedOn()); closeHistoryItem.setDocumentId(closeEvent.getArtifactId()); closeHistoryItem.setEve... |
closeHistoryItem.setClosedBy(closeEventUsers.get(closeEvent.getClosedBy())); | private static CloseHistoryItem buildCloseHistoryItem( final Document document, final CloseEvent closeEvent) { final CloseHistoryItem closeHistoryItem = new CloseHistoryItem(); closeHistoryItem.setDate(closeEvent.getCreatedOn()); closeHistoryItem.setDocumentId(closeEvent.getArtifactId()); closeHistoryItem.setEve... | |
case CLOSE: return buildCloseHistoryItem(document, (CloseEvent) auditEvent); | case CLOSE: return buildCloseHistoryItem(document, (CloseEvent) auditEvent, auditEventUsers); | public static HistoryItem create(final Document document, final AuditEvent auditEvent, final Map<JabberId, User> auditEventUsers) throws ParityException { switch(auditEvent.getType()) { case CLOSE: return buildCloseHistoryItem(document, (CloseEvent) auditEvent); case CREATE: return buildCreateHistoryItem(docume... |
case REQUEST_KEY: return buildRequestKeyHistoryItem(document, (RequestKeyEvent) auditEvent, auditEventUsers); | public static HistoryItem create(final Document document, final AuditEvent auditEvent, final Map<JabberId, User> auditEventUsers) throws ParityException { switch(auditEvent.getType()) { case CLOSE: return buildCloseHistoryItem(document, (CloseEvent) auditEvent); case CREATE: return buildCreateHistoryItem(docume... | |
assertNull(NAME + " [EVENT CONTAINER IS NOT NULL]", e.getContainer()); | assertNotNull(NAME + " EVENT CONTAINER IS NOT NULL", e.getContainer()); | public void containerDeleted(ContainerEvent e) { didNotify = Boolean.TRUE; assertTrue(NAME + " [EVENT GENERATED IS NOT LOCAL]", e.isLocal()); assertTrue(NAME + " [EVENT GENERATED IS REMOTE]", !e.isRemote()); assertNull(NAME + " [EVENT CONTAINER IS NOT NULL]", e.getCon... |
logger.logApiId(); | public void handleReceived(final UUID uniqueId, final Long versionId, final JabberId receivedBy, final Calendar receivedOn) { logger.logApiId(); getArtifactModel().handleReceived(uniqueId, versionId, receivedBy, recei... | |
logger.logTraceId(); | public void teamMemberAdded(final UUID uniqueId, final JabberId jabberId) { getArtifactModel().handleTeamMemberAdded(uniqueId, jabberId); } | |
return new DocumentAdapter() { public void documentClosed(final DocumentEvent e) { if(e.isRemote()) systemApplication.fireDocumentClosed(e.getDocument()); } public void documentCreated(final DocumentEvent e) { if(e.isRemote()) systemApplication.fireDocumentCreated(e.getUser(), e.getDocument()); } public void documentUp... | return new DocumentAdapter() {}; | private DocumentListener createDocumentListener() { return new DocumentAdapter() { public void documentClosed(final DocumentEvent e) { if(e.isRemote()) systemApplication.fireDocumentClosed(e.getDocument()); } public void documentCreated(final Document... |
reloadSendJButtonState(); | public void reload() { reloadDocument(); reloadIncludeKey(); reloadTeamMembers(); reloadContacts(); includeKeyJCheckBox.requestFocusInWindow(); } | |
includeKeyJCheckBox.setSelected(false); | private void reloadIncludeKey() { includeKeyJCheckBox.setVisible(false); if(null != input) { final Boolean isKeyHolder = ArtifactUtil .isKeyHolder(extractDocumentId()); includeKeyJCheckBox.setVisible(isKeyHolder); } } | |
public StringTypeConverterImpl(ValueFactory factory) { super(factory); } | public StringTypeConverterImpl() { super(); } | public StringTypeConverterImpl(ValueFactory factory) { super(factory); } |
if ( null == jcrExpression || "".equals(jcrExpression) ) { jcrExpression = ((FilterImpl) filter).getJcrExpression() ; } else { jcrExpression = "(" + jcrExpression + ") and ( " + ((FilterImpl) filter).getJcrExpression() + ")"; } return this; | FilterImpl theFilter = (FilterImpl) filter; if (theFilter.getJcrExpression() != null && theFilter.getJcrExpression().length() > 0) { if ( null == jcrExpression || "".equals(jcrExpression) ) { jcrExpression = ((FilterImpl) filter).getJcrExpression() ; } else { jcrExpression = "(" + jcrExpression + ") and ( " + (... | public Filter addAndFilter(Filter filter) { if ( null == jcrExpression || "".equals(jcrExpression) ) { jcrExpression = ((FilterImpl) filter).getJcrExpression() ; } else { jcrExpression = "(" + jcrExpression + ") and ( " + ((FilterImpl) filter).getJcrExpression() + ")"; ... |
} | public Filter addOrFilter(Filter filter) { if ( null == jcrExpression || "".equals(jcrExpression) ) { jcrExpression = ((FilterImpl) filter).getJcrExpression() ; } else { jcrExpression = "(" + jcrExpression + ") or ( " + ((FilterImpl) filter).g... | |
final void setLibraryParameters(final String listName, final String name, | public final void setLibraryParameters(final String listName, final String name, | final void setLibraryParameters(final String listName, final String name, final List<Library> values) { final List<Parameter> parameters = new LinkedList<Parameter>(); for(final Library value : values) parameters.add(new Parameter(name, Library.class, value)); this.paramet... |
publishToContacts(OpheliaTestUser.JUNIT, container, OpheliaTestUser.JUNIT_X.getName()); | publishToContacts(OpheliaTestUser.JUNIT, container.getId(), OpheliaTestUser.JUNIT_X.getName()); | protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); final ContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); addDocuments(OpheliaTestUser.JUNIT, cont... |
this.javaProperties = load(workspace, getFile(workspace)); | this.javaProperties = load(file); | private PersistenceFactory() { super(); final ModelFactory modelFactory = ModelFactory.getInstance(); final Workspace workspace = modelFactory.getWorkspace(PersistenceFactory.class); this.cache = new Hashtable<Class, Persistence>(7, 0.75F); this.javaProperties = load(workspace, getFile(workspace)); /... |
public void run() { store(workspace); } | public void run() { store(javaProperties, file); } | private PersistenceFactory() { super(); final ModelFactory modelFactory = ModelFactory.getInstance(); final Workspace workspace = modelFactory.getWorkspace(PersistenceFactory.class); this.cache = new Hashtable<Class, Persistence>(7, 0.75F); this.javaProperties = load(workspace, getFile(workspace)); /... |
public void run() { store(workspace); } | public void run() { store(javaProperties, file); } | public void run() { store(workspace); } |
private void init(final Workspace workspace, final File persistenceFile) throws IOException { if(!persistenceFile.exists()) { | private void init(final File file) throws IOException { if(!file.exists()) { | private void init(final Workspace workspace, final File persistenceFile) throws IOException { if(!persistenceFile.exists()) { Assert.assertTrue( "[LBROWSER] [PLATFORM] [UTIL] [PERSISTENCE FACTORY INIT] [CANNOT CREATE PERSISTENCE FILE]", persistenceFile.createNewFile(... |
persistenceFile.createNewFile()); store(workspace); | file.createNewFile()); | private void init(final Workspace workspace, final File persistenceFile) throws IOException { if(!persistenceFile.exists()) { Assert.assertTrue( "[LBROWSER] [PLATFORM] [UTIL] [PERSISTENCE FACTORY INIT] [CANNOT CREATE PERSISTENCE FILE]", persistenceFile.createNewFile(... |
private Properties load(final Workspace workspace, final File persistenceFile) { try { init(workspace, persistenceFile); } | private Properties load(final File file) { try { init(file); } | private Properties load(final Workspace workspace, final File persistenceFile) { try { init(workspace, persistenceFile); } catch(final IOException iox) { throw new RuntimeException(iox); } final Properties javaProperties = new Properties(); try { javaProperties.load(new FileInputStream(persistenceFile))... |
final Properties javaProperties = new Properties(); try { javaProperties.load(new FileInputStream(persistenceFile)); } | final Properties properties = new Properties(); try { properties.load(new FileInputStream(file)); } | private Properties load(final Workspace workspace, final File persistenceFile) { try { init(workspace, persistenceFile); } catch(final IOException iox) { throw new RuntimeException(iox); } final Properties javaProperties = new Properties(); try { javaProperties.load(new FileInputStream(persistenceFile))... |
return javaProperties; | return properties; | private Properties load(final Workspace workspace, final File persistenceFile) { try { init(workspace, persistenceFile); } catch(final IOException iox) { throw new RuntimeException(iox); } final Properties javaProperties = new Properties(); try { javaProperties.load(new FileInputStream(persistenceFile))... |
private void store(final Workspace workspace) { try { javaProperties.store(new FileOutputStream(getFile(workspace)), ""); } | private void store(final Properties properties, final File file) { try { properties.store(new FileOutputStream(file), ""); } | private void store(final Workspace workspace) { try { javaProperties.store(new FileOutputStream(getFile(workspace)), ""); } catch(final IOException iox) { throw new RuntimeException(iox); } } |
public CalendarTypeConverterImpl(ValueFactory factory) { super(factory); } | public CalendarTypeConverterImpl() { super(); } | public CalendarTypeConverterImpl(ValueFactory factory) { super(factory); } |
User readUser() { | User readUser(final JabberId userId) { | User readUser() { logger.logApiId(); try { final XMPPSession xmppSession = workspace.getXMPPSession(); synchronized (xmppSession) { return xmppSession.readCurrentUser(); } } catch (final Throwable t) { throw translateError(t); } ... |
return xmppSession.readCurrentUser(); | return xmppSession.readUser(userId); | User readUser() { logger.logApiId(); try { final XMPPSession xmppSession = workspace.getXMPPSession(); synchronized (xmppSession) { return xmppSession.readCurrentUser(); } } catch (final Throwable t) { throw translateError(t); } ... |
case 8: return KEY_REQUEST_DENIED; case 9: return KEY_RESPONSE_DENIED; | public static AuditEventType fromId(final Integer id) { switch(id) { case 0: return ARCHIVE; case 1: return CLOSE; case 2: return CREATE; case 3: return RECEIVE; case 4: return RECEIVE_KEY; case 5: return REQUEST_KEY; case 6: return SEND; case 7: return SEND_KEY; default: throw Assert.createUnreachable("Co... | |
public ByteArrayTypeConverterImpl(ValueFactory factory) { super(factory); } | public ByteArrayTypeConverterImpl() { super(); } | public ByteArrayTypeConverterImpl(ValueFactory factory) { super(factory); } |
public DeleteSystemMessage() { super("DeleteSystemMessage", ID, NAME, ICON); } | public DeleteSystemMessage(final Browser browser) { super("DeleteSystemMessage", ID, NAME, ICON); this.browser = browser; } | public DeleteSystemMessage() { super("DeleteSystemMessage", ID, NAME, ICON); } |
try { getSystemMessageModel().delete(messageId); } catch(final ParityException px) { throw new RuntimeException(px); } | getSystemMessageModel().delete(messageId); browser.fireSystemMessageDeleted(messageId); | public void invoke(final Data data) throws Exception { final Long messageId = (Long) data.get(DataKey.SYSTEM_MESSAGE_ID); try { getSystemMessageModel().delete(messageId); } catch(final ParityException px) { throw new RuntimeException(px); } } |
public LongTypeConverterImpl(ValueFactory factory) { super(factory); } | public LongTypeConverterImpl() { super(); } | public LongTypeConverterImpl(ValueFactory factory) { super(factory); } |
return export(exportDirectory, container, versions); | return export(exportDirectory, getNameGenerator().exportFileName(container), container, versions); | File export(final File exportDirectory, final Long containerId) { logger.logApiId(); logger.logVariable("exportDirectory", exportDirectory); logger.logVariable("containerId", containerId); try { Assert.assertTrue(exportDirectory.isDirectory(), "Export direct... |
versions.add(readVersion(containerId, versionId)); return export(exportDirectory, container, versions); | final ContainerVersion version = readVersion(containerId, versionId); versions.add(version); return export(exportDirectory, getNameGenerator().exportFileName(version), container, versions); | File exportVersion(final File exportDirectory, final Long containerId, final Long versionId) { logger.logApiId(); logger.logVariable("exportDirectory", exportDirectory); logger.logVariable("containerId", containerId); logger.logVariable("versionId", versionId); try { ... |
if (null != draft) { final List<Document> documents = new ArrayList<Document>(); documents.addAll(draft.getDocuments()); ModelSorter.sortDocuments(documents, defaultComparator); draft.setDocuments(documents); } | ContainerDraft readDraft(final Long containerId) { logger.logApiId(); logger.logVariable("containerId", containerId); final InternalDocumentModel documentModel = getInternalDocumentModel(); final ContainerDraft draft = containerIO.readDraft(containerId); if (null != draft) { ... | |
return getInternalArtifactModel().readTeam2(containerId); | return getInternalArtifactModel().readTeam(containerId, UserComparatorFactory.createName(Boolean.TRUE), FilterManager.createDefault()); | List<TeamMember> readTeam(final Long containerId) { logger.logApiId(); logger.logVariable("containerId", containerId); return getInternalArtifactModel().readTeam2(containerId); } |
private Fixture(final Container container, final ContainerModel containerModel) { this.containerModel = containerModel; this.container = container; | private Fixture(final OpheliaTestUser junit, final OpheliaTestUser junit_x, final OpheliaTestUser junit_y) { this.junit = junit; this.junit_x = junit_x; this.junit_y = junit_y; | private Fixture(final Container container, final ContainerModel containerModel) { this.containerModel = containerModel; this.container = container; this.didNotify = Boolean.FALSE; } |
addQueueHelper(junit); addQueueHelper(junit_x); addQueueHelper(junit_y); | private Fixture(final Container container, final ContainerModel containerModel) { this.containerModel = containerModel; this.container = container; this.didNotify = Boolean.FALSE; } | |
login(OpheliaTestUser.JUNIT); final ContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); datum = new Fixture(container, containerModel); datum.containerModel.addListener(datum); | datum = new Fixture(OpheliaTestUser.JUNIT, OpheliaTestUser.JUNIT_X, OpheliaTestUser.JUNIT_Y); login(datum.junit); login(datum.junit_x); login(datum.junit_y); | protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); final ContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); datum = new Fixture(container, container... |
datum.containerModel.removeListener(datum); | logout(datum.junit); logout(datum.junit_x); logout(datum.junit_y); | protected void tearDown() throws Exception { datum.containerModel.removeListener(datum); datum = null; logout(OpheliaTestUser.JUNIT); super.tearDown(); } |
logout(OpheliaTestUser.JUNIT); | protected void tearDown() throws Exception { datum.containerModel.removeListener(datum); datum = null; logout(OpheliaTestUser.JUNIT); super.tearDown(); } | |
datum.containerModel.delete(datum.container.getId()); | final Container c = createContainer(datum.junit, NAME); getContainerModel(datum.junit).addListener(datum); logger.logInfo("Deleting container \"{0}\" as \"{1}.\"", c.getName(), datum.junit_x.getSimpleUsername()); getContainerModel(datum.junit).delete(c.getId()); getContainerModel(datum.junit).removeListener(datum); | public void testDelete() { datum.containerModel.delete(datum.container.getId()); final Container container = datum.containerModel.read(datum.container.getId()); assertNull(NAME + " [CONTAINER IS NOT NULL]", container); assertTrue(NAME + " [CONTAINER DELETION EVENT NOT FIRED]", datum.didN... |
final Container container = datum.containerModel.read(datum.container.getId()); assertNull(NAME + " [CONTAINER IS NOT NULL]", container); assertTrue(NAME + " [CONTAINER DELETION EVENT NOT FIRED]", datum.didNotify); | final Container cRead = getContainerModel(datum.junit).read(c.getId()); assertNull("Container \"" + c.getName() + "\" was not deleted.", cRead); assertTrue("Container deleted event was not fired for container \"" + c.getName() + ".\"", datum.didNotify); | public void testDelete() { datum.containerModel.delete(datum.container.getId()); final Container container = datum.containerModel.read(datum.container.getId()); assertNull(NAME + " [CONTAINER IS NOT NULL]", container); assertTrue(NAME + " [CONTAINER DELETION EVENT NOT FIRED]", datum.didN... |
FileInputStream fis = null; | final InputStream stream = new FileInputStream(getManifestFile()); | public Boolean isComplete() throws IOException { if(getManifestFile().exists()) { FileInputStream fis = null; try { fis = new FileInputStream(getManifestFile()); manifest.load(new FileInputStream(getManifestFile())); File libraryFile; ... |
fis = new FileInputStream(getManifestFile()); manifest.load(new FileInputStream(getManifestFile())); File libraryFile; for(final Object key : manifest.keySet()) { libraryFile = new File(fsHelper.getRoot(), manifest.getProperty((String) key)); if(!libraryFile.exists()) { return Boolean.FALSE; } } return Boolean.TRUE; | manifest.load(stream); } finally { stream.close(); | public Boolean isComplete() throws IOException { if(getManifestFile().exists()) { FileInputStream fis = null; try { fis = new FileInputStream(getManifestFile()); manifest.load(new FileInputStream(getManifestFile())); File libraryFile; ... |
finally { fis.close(); } | File libraryFile; for(final Object key : manifest.keySet()) { libraryFile = new File(fsHelper.getRoot(), manifest.getProperty((String) key)); if(!libraryFile.exists()) { return Boolean.FALSE; } } return Boolean.TRUE; | public Boolean isComplete() throws IOException { if(getManifestFile().exists()) { FileInputStream fis = null; try { fis = new FileInputStream(getManifestFile()); manifest.load(new FileInputStream(getManifestFile())); File libraryFile; ... |
public String getDisplay() { return document.getName(); } | public String getDisplay() { if(DISPLAY_MAX_LENGTH < document.getName().length()) { return document.getName().substring(0, DISPLAY_MAX_LENGTH - 1 - 3) + "..."; } else { return document.getName(); } } | public String getDisplay() { return document.getName(); } |
this.versionModel = new DefaultComboBoxModel(); | public SessionSendFormAvatar() { // COLOR Send Form Background super("SessionSendForm", Color.WHITE); this.contactsModel = new DefaultListModel(); this.contactsSelectionModel = new DefaultListSelectionModel(); this.teamModel = new DefaultListModel(); this.teamSelectionModel = new DefaultListSelectionModel(... | |
contactsSelectionModel.setSelectionMode( ListSelectionModel.SINGLE_SELECTION); teamSelectionModel.setSelectionMode( ListSelectionModel.SINGLE_SELECTION); | private void includeKeyJCheckBoxStateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_includeKeyJCheckBoxStateChanged if(includeKeyIsSelected != includeKeyJCheckBox.isSelected()) { if(includeKeyJCheckBox.isSelected()) { contactsSelectionModel.setSelectionMode( ListSelectionModel.SINGLE_SELEC... | |
int[] indices = teamJList.getSelectedIndices(); if(1 < indices.length) { for(int i = 1; i < indices.length; i++) { | final int[] teamIndices = teamJList.getSelectedIndices(); if(1 < teamIndices.length) { for(int i = 1; i < teamIndices.length; i++) { | private void includeKeyJCheckBoxStateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_includeKeyJCheckBoxStateChanged if(includeKeyIsSelected != includeKeyJCheckBox.isSelected()) { if(includeKeyJCheckBox.isSelected()) { contactsSelectionModel.setSelectionMode( ListSelectionModel.SINGLE_SELEC... |
else { indices = contactsJList.getSelectedIndices(); if(1 < indices.length) { for(int i = 1; i < indices.length; i++) { contactsSelectionModel.removeSelectionInterval(i, i); } } } | else { final int[] contactIndices = contactsJList.getSelectedIndices(); if(0 < teamIndices.length && 0 < contactIndices.length) { contactsSelectionModel.clearSelection(); } } final int[] contactIndices = contactsJList.getSelectedIndices(); if(1 < contactIndices.length) { for(int i = 1; i < contactIndices.length; i++) ... | private void includeKeyJCheckBoxStateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_includeKeyJCheckBoxStateChanged if(includeKeyIsSelected != includeKeyJCheckBox.isSelected()) { if(includeKeyJCheckBox.isSelected()) { contactsSelectionModel.setSelectionMode( ListSelectionModel.SINGLE_SELEC... |
reloadVersions(); | private void includeKeyJCheckBoxStateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_includeKeyJCheckBoxStateChanged if(includeKeyIsSelected != includeKeyJCheckBox.isSelected()) { if(includeKeyJCheckBox.isSelected()) { contactsSelectionModel.setSelectionMode( ListSelectionModel.SINGLE_SELEC... | |
javax.swing.JLabel versionJLabel; | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... | |
documentJLabel = LabelFactory.create(); versionJLabel = LabelFactory.create(getString("VersionLabel")); versionJComboBox = ComboBoxFactory.create(); | documentJLabel = LabelFactory.create(getString("DocumentLabel")); | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
versionJComboBox.setModel(versionModel); versionJComboBox.setRenderer(new VersionListCellRenderer()); versionJComboBox.addItemListener(new java.awt.event.ItemListener() { public void itemStateChanged(java.awt.event.ItemEvent e) { versionJComboBoxItemStateChanged(e); } }); | documentNameJLabel = new javax.swing.JLabel(); | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(teamJScrollPane, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 173, Short.MAX_VALUE)) | .add(teamJScrollPane, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 193, Short.MAX_VALUE)) | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() | .add(layout.createSequentialGroup() | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(org.jdesktop.layout.GroupLayout.LEADING, sendToJPanel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(documentJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 360, Short... | .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup() | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(org.jdesktop.layout.GroupLayout.LEADING, jSeparator_1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 360, Short.MAX_VALUE) | .add(vSpacerJLabel) .add(jSeparator_1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 380, Short.MAX_VALUE) .add(sendToJPanel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(versionJLabel) .add(vSpacerJLabel)) | .add(documentJLabel) | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(org.jdesktop.layout.GroupLayout.TRAILING, includeKeyJCheckBox, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 309, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.TRAILING, versionJComboBox, 0, 309, Short.MAX_VALUE)))) | .add(includeKeyJCheckBox, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 318, Short.MAX_VALUE) .add(documentNameJLabel, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 318, Short.MAX_VALUE)))) | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(documentJLabel) | .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(documentJLabel) .add(documentNameJLabel)) | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
.add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(versionJLabel) .add(versionJComboBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .a... | .add(includeKeyJCheckBox) .add(10, 10, 10) .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(vSpacerJLabel) .add(jSeparator_1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 10, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) | private void initComponents() { javax.swing.JButton cancelJButton; javax.swing.JLabel contactsJLabel; javax.swing.JScrollPane contactsJScrollPane; javax.swing.JSeparator jSeparator_1; javax.swing.JLabel teamJLabel; javax.swing.JScrollPane teamJScrollPane; javax.swing... |
teamJListValueChanged(e); | contactsJListValueChanged(e); | public void valueChanged(javax.swing.event.ListSelectionEvent e) { teamJListValueChanged(e); } |
sendJButtonActionPerformed(e); | cancelJButtonActionPerformed(e); | public void actionPerformed(java.awt.event.ActionEvent e) { sendJButtonActionPerformed(e); } |
final DocumentVersion version = extractDocumentVersion(); if(null == version) { return Boolean.FALSE; } if(doIncludeKey) { if(version != WorkingVersion.getWorkingVersion()) { return Boolean.FALSE; } } | public Boolean isInputValid() { Long documentId; try { documentId = extractDocumentId(); } catch(final Throwable t) { return Boolean.FALSE; } Collection<Contact> contacts = null; try { contacts = extractTeam(); } catch(final Throwable t) { return Boolean.FALSE; } try { contacts.addAll(extractContacts()); } ... | |
reloadVersions(); | public void reload() { reloadDocument(); reloadIncludeKey(); reloadTeamMembers(); reloadContacts(); reloadVersions(); versionJComboBox.requestFocusInWindow(); } | |
versionJComboBox.requestFocusInWindow(); | includeKeyJCheckBox.requestFocusInWindow(); | public void reload() { reloadDocument(); reloadIncludeKey(); reloadTeamMembers(); reloadContacts(); reloadVersions(); versionJComboBox.requestFocusInWindow(); } |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.