bugged
stringlengths
6
599k
fixed
stringlengths
10
599k
__index_level_0__
int64
0
1.13M
public ThreadedSocketInitiator(Application application, MessageStoreFactory messageStoreFactory, SessionSettings settings, MessageFactory messageFactory) throws ConfigError { super(application, messageStoreFactory, settings, messageFactory); }
public ThreadedSocketInitiator(Application application, MessageStoreFactory messageStoreFactory, SessionSettings settings, MessageFactory messageFactory) throws ConfigError { super(application, messageStoreFactory, settings, messageFactory); }
1,113,422
UserNameBuilder(final String first, final String middle, final String last) { super(); if(null == first) { throw new NullPointerException(); } if(null == last) { throw new NullPointerException(); } this.first = first; this.middle = middle; this.last = last; }
UserNameBuilder(final String first, final String middle, final String last) { super(); if(null == first) { throw new NullPointerException(); } if(null == last) { throw new NullPointerException(); } this.first = first; this.middle = middle; this.last = last; }
1,113,423
UserNameBuilder(final String first, final String middle, final String last) { super(); if(null == first) { throw new NullPointerException(); } if(null == last) { throw new NullPointerException(); } this.first = first; this.middle = middle; this.last = last; }
UserNameBuilder(final String first, final String middle, final String last) { super(); if(null == first) { throw new NullPointerException(); } if(null == last) { throw new NullPointerException(); } this.first = first; this.middle = middle; this.last = last; }
1,113,424
UserNameBuilder(final String first, final String middle, final String last) { super(); if(null == first) { throw new NullPointerException(); } if(null == last) { throw new NullPointerException(); } this.first = first; this.middle = middle; this.last = last; }
UserNameBuilder(final String first, final String middle, final String last) { super(); if(null == first) { throw new NullPointerException(); } if(null == last) { throw new NullPointerException(); } this.first = first; this.middle = null; this.last = last; }
1,113,425
public String getName() { if(null == first || null == last) { return null; } final StringBuffer name = new StringBuffer(first); if(null != middle) { name.append(User.NAME_SEP).append(middle); } name.append(User.NAME_SEP).append(last); return name.toString(); }
public String getName() { if(null == first || null == last) { return null; } final StringBuffer name = new StringBuffer(first); if(null != middle) { name.append(User.NAME_SEP).append(middle); } name.append(User.NAME_SEP).append(last); return name.toString(); }
1,113,426
public void run() { Logger.getLogger(getClass()).trace("Runtime shutting down."); synchronized (WORKSPACES) { List<ShutdownHook> shutdownHooks; for (final WorkspaceImpl workspace : WORKSPACES) { Logger.getLogger(getClass()).trace( MessageFormat.format("Workspace {0} shutting down.", workspace.getName())); shutdownHooks = workspace.getShutdownHooks(); for(final ShutdownHook shutdownHook : shutdownHooks) { Logger.getLogger(getClass()).trace( MessageFormat.format("Workspace {0} priority {1} hook {2} shutting down.", workspace.getName(), shutdownHook.getPriority(), shutdownHook.getName())); shutdownHook.run(); } } } }
public void run() { Logger.getLogger(getClass()).trace("Runtime shutting down."); synchronized (WORKSPACES) { List<ShutdownHook> shutdownHooks; for (final WorkspaceImpl workspace : WORKSPACES.values()) { Logger.getLogger(getClass()).trace( MessageFormat.format("Workspace {0} shutting down.", workspace.getName())); shutdownHooks = workspace.getShutdownHooks(); for(final ShutdownHook shutdownHook : shutdownHooks) { Logger.getLogger(getClass()).trace( MessageFormat.format("Workspace {0} priority {1} hook {2} shutting down.", workspace.getName(), shutdownHook.getPriority(), shutdownHook.getName())); shutdownHook.run(); } } } }
1,113,428
private WorkspaceImpl findImpl(final Workspace workspace) { synchronized (WORKSPACES) { for (final WorkspaceImpl impl : WORKSPACES) { if (impl.getWorkspaceDirectory().equals(workspace.getWorkspaceDirectory())) { return impl; } } } return null; }
private WorkspaceImpl findImpl(final Workspace workspace) { synchronized (WORKSPACES) { for (final WorkspaceImpl impl : WORKSPACES.values()) { if (impl.getWorkspaceDirectory().equals(workspace.getWorkspaceDirectory())) { return impl; } } } return null; }
1,113,429
Workspace getWorkspace(final File workspace) { synchronized (WORKSPACES) { final WorkspaceImpl impl = new WorkspaceImpl(workspace); if (WORKSPACES.contains(impl)) { return WORKSPACES.get(WORKSPACES.indexOf(impl)); } else { WORKSPACES.add(open(impl)); return getWorkspace(workspace); } } }
Workspace getWorkspace(final File workspace) { synchronized (WORKSPACES) { final WorkspaceImpl impl = new WorkspaceImpl(workspace); if (WORKSPACES.contains(impl)) { return WORKSPACES.get(WORKSPACES.indexOf(impl)); } else { WORKSPACES.add(open(impl)); return getWorkspace(workspace); } } }
1,113,430
Workspace getWorkspace(final File workspace) { synchronized (WORKSPACES) { final WorkspaceImpl impl = new WorkspaceImpl(workspace); if (WORKSPACES.contains(impl)) { return WORKSPACES.get(WORKSPACES.indexOf(impl)); } else { WORKSPACES.add(open(impl)); return getWorkspace(workspace); } } }
Workspace getWorkspace(final File workspace) { synchronized (WORKSPACES) { final WorkspaceImpl impl = new WorkspaceImpl(workspace); if (WORKSPACES.contains(impl)) { return WORKSPACES.get(WORKSPACES.indexOf(impl)); } else { final WorkspaceImpl impl = new WorkspaceImpl(workspace); WORKSPACES.put(workspace, open(impl)); return getWorkspace(workspace); } } }
1,113,431
public File[] list(final String path, final FileFilter filter) { return list(path, filter, Boolean.FALSE); }
public File[] list(final String path, final FileFilter filter) { return list(path, filter, Boolean.FALSE); }
1,113,432
public void deleteVersion(Long containerId, Long versionId) { final Session session = openSession(); try { final Integer publishedToCount = readPublishedToCount(containerId, versionId); session.prepareStatement(SQL_DELETE_PUBLISHED_TO); session.setLong(1, containerId); session.setLong(2, versionId); final Integer publishedToDeleted = session.executeUpdate(); if (publishedToCount != publishedToDeleted) throw translateError( "Could only delete {0} of {1} published to rows.", publishedToDeleted, publishedToCount); deleteSharedWith(session, containerId, versionId); session.prepareStatement(SQL_DELETE_VERSION); session.setLong(1, containerId); session.setLong(2, versionId); if(1 != session.executeUpdate()) throw new HypersonicException("Could not delete version."); artifactIO.deleteVersion(session, containerId, versionId); session.commit(); } catch (final Throwable t) { session.rollback(); throw translateError(t); } finally { session.close(); } }
public void deleteVersion(Long containerId, Long versionId) { final Session session = openSession(); try { final int publishedToCount = readPublishedToCount(containerId, versionId); session.prepareStatement(SQL_DELETE_PUBLISHED_TO); session.setLong(1, containerId); session.setLong(2, versionId); final Integer publishedToDeleted = session.executeUpdate(); if (publishedToCount != publishedToDeleted) throw translateError( "Could only delete {0} of {1} published to rows.", publishedToDeleted, publishedToCount); deleteSharedWith(session, containerId, versionId); session.prepareStatement(SQL_DELETE_VERSION); session.setLong(1, containerId); session.setLong(2, versionId); if(1 != session.executeUpdate()) throw new HypersonicException("Could not delete version."); artifactIO.deleteVersion(session, containerId, versionId); session.commit(); } catch (final Throwable t) { session.rollback(); throw translateError(t); } finally { session.close(); } }
1,113,433
public void deleteVersion(Long containerId, Long versionId) { final Session session = openSession(); try { final Integer publishedToCount = readPublishedToCount(containerId, versionId); session.prepareStatement(SQL_DELETE_PUBLISHED_TO); session.setLong(1, containerId); session.setLong(2, versionId); final Integer publishedToDeleted = session.executeUpdate(); if (publishedToCount != publishedToDeleted) throw translateError( "Could only delete {0} of {1} published to rows.", publishedToDeleted, publishedToCount); deleteSharedWith(session, containerId, versionId); session.prepareStatement(SQL_DELETE_VERSION); session.setLong(1, containerId); session.setLong(2, versionId); if(1 != session.executeUpdate()) throw new HypersonicException("Could not delete version."); artifactIO.deleteVersion(session, containerId, versionId); session.commit(); } catch (final Throwable t) { session.rollback(); throw translateError(t); } finally { session.close(); } }
public void deleteVersion(Long containerId, Long versionId) { final Session session = openSession(); try { final Integer publishedToCount = readPublishedToCount(containerId, versionId); session.prepareStatement(SQL_DELETE_PUBLISHED_TO); session.setLong(1, containerId); session.setLong(2, versionId); final int publishedToDeleted = session.executeUpdate(); if (publishedToCount != publishedToDeleted) throw translateError( "Could only delete {0} of {1} published to rows.", publishedToDeleted, publishedToCount); deleteSharedWith(session, containerId, versionId); session.prepareStatement(SQL_DELETE_VERSION); session.setLong(1, containerId); session.setLong(2, versionId); if(1 != session.executeUpdate()) throw new HypersonicException("Could not delete version."); artifactIO.deleteVersion(session, containerId, versionId); session.commit(); } catch (final Throwable t) { session.rollback(); throw translateError(t); } finally { session.close(); } }
1,113,434
public Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) { final UUID uniqueId = readUniqueId(reader, context); final Long versionId = readVersionId(reader, context); final String name = readName(reader, context); final String createdBy = readCreatedBy(reader, context); final Calendar createdOn = readCreatedOn(reader, context); final String updatedBy = readUpdatedBy(reader, context); final Calendar updatedOn = readUpdatedOn(reader, context); final String description = readDescription(reader, context); final byte[] content; try { content = readContent(reader, context); } catch(DataFormatException dfx) { logger.error("unmarshal(HierarchicalStreamReader,UnmarshallingContext)", dfx); throw XmlIOConverterErrorTranslator.translate(dfx); } catch(IOException iox) { logger.error("unmarshal(HierarchicalStreamReader,UnmarshallingContext)", iox); throw XmlIOConverterErrorTranslator.translate(iox); } return XMPPDocument.create(content, createdBy, createdOn, description, name, uniqueId, updatedBy, updatedOn, versionId); }
public Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) { final UUID uniqueId = readUniqueId(reader, context); final Long versionId = readVersionId(reader, context); final String name = readName(reader, context); final String createdBy = readCreatedBy(reader, context); final Calendar createdOn = readCreatedOn(reader, context); final String updatedBy = readUpdatedBy(reader, context); final Calendar updatedOn = readUpdatedOn(reader, context); final String description = readDescription(reader, context); final byte[] content; try { content = readContent(reader, context); } catch(DataFormatException dfx) { logger.error("unmarshal(HierarchicalStreamReader,UnmarshallingContext)", dfx); throw XmlIOConverterErrorTranslator.translate(dfx); } catch(IOException iox) { logger.error("unmarshal(HierarchicalStreamReader,UnmarshallingContext)", iox); throw XmlIOConverterErrorTranslator.translate(iox); } return XMPPDocument.create(content, createdBy, createdOn, description, name, receivedFrom, uniqueId, updatedBy, updatedOn, versionId); }
1,113,436
<T extends XMPPEvent> void notifyHandler(final T event) { final XMPPEventHandler<T> handler; synchronized (registry) { handler = registry.get(event.getClass()); } if (null == handler) { logger.logWarning("No handler has been registered for event {0}.", event.getClass()); } else { handler.handleEvent(event); } }
<T extends XMPPEvent> void notifyHandler(final T event) { final XMPPEventHandler<T> handler; synchronized (registry) { handler = registry.get(event.getClass()); } if (null == handler) { logger.logWarning("No handler has been registered for event {0}.", event.getClass()); } else { handler.handleEvent(event); } }
1,113,437
private void setMnemonicAndAccelerator() { if (action.isSetMnemonic()) { putValue(MNEMONIC_KEY, new Integer(action.getMnemonic().charAt(0))); } if (action.isSetAccelerator()) { putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(action.getAccelerator())); } }
private void setMnemonicAndAccelerator() { if (action.isSetMnemonic()) { putValue(MNEMONIC_KEY, Integer.valueOf(action.getMnemonic().charAt(0))); } if (action.isSetAccelerator()) { putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(action.getAccelerator())); } }
1,113,440
public QueryHit toQueryHit(final Hit hit) { final QueryHit queryHit = new QueryHit(); try { queryHit.setDataId(parseLong(hit, idField)); } catch(final IOException iox) { throw new IndexException("Could not extract hit value.", iox); } return queryHit; }
public QueryHit toQueryHit(final Hit hit) { final QueryHit queryHit = new QueryHit(); try { queryHit.setDataId(parseLong(hit, idField)); queryHit.setDocument(hit.getDocument()); } catch(final IOException iox) { throw new IndexException("Could not extract hit value.", iox); } return queryHit; }
1,113,441
protected void setUp() throws Exception { super.setUp(); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final Document document = addDocument(OpheliaTestUser.JUNIT, container, getInputFiles()[0]); login(OpheliaTestUser.JUNIT); publishToContacts(OpheliaTestUser.JUNIT, container); createContainerDraft(OpheliaTestUser.JUNIT, container); modifyDocument(OpheliaTestUser.JUNIT, document); logout(OpheliaTestUser.JUNIT); datum = new Fixture(container, containerModel, document); datum.containerModel.addListener(datum); }
protected void setUp() throws Exception { super.setUp(); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final Document document = addDocument(OpheliaTestUser.JUNIT, container, getInputFiles()[0]); login(OpheliaTestUser.JUNIT); publishToContacts(OpheliaTestUser.JUNIT, container); createContainerDraft(OpheliaTestUser.JUNIT, container); modifyDocument(OpheliaTestUser.JUNIT, document.getId()); logout(OpheliaTestUser.JUNIT); datum = new Fixture(container, containerModel, document); datum.containerModel.addListener(datum); }
1,113,442
protected void publishToContacts(final OpheliaTestUser testUser, final Container container, final String... contactNames) { final List<Contact> contacts = readContacts(testUser); userUtils.filter(contacts, contactNames); final List<TeamMember> teamMembers = Collections.emptyList(); logTrace("{0} - Publishing container {1} to contacts {2} and team members {3}.", getName(), container.getName(), contacts, teamMembers); getContainerModel(testUser).publish(container.getId(), contacts, teamMembers); }
protected void publishToContacts(final OpheliaTestUser testUser, final Container container) { final List<TeamMember> teamMembers = Collections.emptyList(); final List<Contact> contacts = readContacts(testUser); userUtils.filter(contacts, contactNames); final List<TeamMember> teamMembers = Collections.emptyList(); logTrace("{0} - Publishing container {1} to contacts {2} and team members {3}.", getName(), container.getName(), contacts, teamMembers); getContainerModel(testUser).publish(container.getId(), contacts, teamMembers); }
1,113,443
protected void publishToContacts(final OpheliaTestUser testUser, final Container container, final String... contactNames) { final List<Contact> contacts = readContacts(testUser); userUtils.filter(contacts, contactNames); final List<TeamMember> teamMembers = Collections.emptyList(); logTrace("{0} - Publishing container {1} to contacts {2} and team members {3}.", getName(), container.getName(), contacts, teamMembers); getContainerModel(testUser).publish(container.getId(), contacts, teamMembers); }
protected void publishToContacts(final OpheliaTestUser testUser, final Container container, final String... contactNames) { final List<Contact> contacts = readContacts(testUser); userUtils.filter(contacts, contactNames); final List<TeamMember> teamMembers = Collections.emptyList(); logTrace("{0} - Publishing container {1} to contacts {2} and team members {3}.", getName(), container.getName(), contacts, teamMembers); getContainerModel(testUser).publish(container.getId(), contacts, teamMembers); }
1,113,444
void processEventQueue(final JabberId userId) { logger.logApiId(); logger.logVariable("userId", userId); final XMPPMethod processOfflineQueue = new XMPPMethod("system:readqueueevents"); processOfflineQueue.setParameter("userId", userId); final List<XMPPEvent> events = execute(processOfflineQueue, Boolean.TRUE).readResultEvents("events"); for (final XMPPEvent event : events) { logger.logVariable("event", event); notifyHandler(event); deleteQueueEvent(userId, event.getId()); } }
void processEventQueue(final JabberId userId) { logger.logApiId(); logger.logVariable("userId", userId); final XMPPMethod processOfflineQueue = new XMPPMethod("system:readqueueevents"); processOfflineQueue.setParameter("userId", userId); final List<XMPPEvent> events = execute(processOfflineQueue, Boolean.TRUE).readResultEvents("events"); for (final XMPPEvent event : events) { logger.logVariable("event", event); notifyHandler(event); deleteQueueEvent(userId, event.getId()); } }
1,113,446
protected ParityObject(final Project parent, final String name, final String description, final Calendar createdOn, final String createdBy, final String keyHolder, final UUID id) { super(); this.parent = parent; this.name = name; this.description = description; this.createdOn = createdOn; this.createdBy = createdBy; this.keyHolder = keyHolder; this.notes = new Vector<Note>(7); this.customProperties = new Properties(createDefaultCustomProperties(name, description)); this.id = id; }
protected ParityObject(final Project parent, final String name, final String description, final Calendar createdOn, final String createdBy, final String keyHolder, final UUID id) { super(); this.parent = parent; this.name = name; this.description = description; this.createdOn = createdOn; this.createdBy = createdBy; this.keyHolder = keyHolder; this.notes = new Vector<Note>(7); this.customProperties = new Properties(createDefaultCustomProperties(name, description)); this.id = id; }
1,113,447
protected ParityObject(final Project parent, final String name, final String description, final Calendar createdOn, final String createdBy, final String keyHolder, final UUID id) { super(); this.parent = parent; this.name = name; this.description = description; this.createdOn = createdOn; this.createdBy = createdBy; this.keyHolder = keyHolder; this.notes = new Vector<Note>(7); this.customProperties = new Properties(createDefaultCustomProperties(name, description)); this.id = id; }
protected ParityObject(final Project parent, final String name, final String description, final Calendar createdOn, final String createdBy, final String keyHolder, final UUID id) { super(); this.parent = parent; this.name = name; this.description = description; this.createdOn = createdOn; this.createdBy = createdBy; this.notes = new Vector<Note>(7); this.customProperties = new Properties(createDefaultCustomProperties(name, description)); this.id = id; }
1,113,448
Boolean doesExist(final Long artifactId) { logger.logApiId(); logger.logVariable("variable", artifactId); return null != artifactIO.readUniqueId(artifactId); }
Boolean doesExist(final Long artifactId) { logger.logApiId(); logger.logVariable("variable", artifactId); return null != artifactIO.readUniqueId(artifactId); }
1,113,449
void handleTeamMemberRemoved(final ArtifactTeamMemberRemovedEvent event) { logger.logApiId(); logger.logVariable("event", event); try { final Long artifactId = readId(event.getUniqueId()); artifactIO.deleteTeamRel(artifactId); } catch(final Throwable t) { throw translateError(t); } }
void handleTeamMemberRemoved(final ArtifactTeamMemberRemovedEvent event) { logger.logApiId(); logger.logVariable("event", event); try { final Long artifactId = readId(event.getUniqueId()); final User user = getInternalUserModel().read(event.getJabberId()); artifactIO.deleteTeamRel(artifactId, user.getLocalId()); } catch(final Throwable t) { throw translateError(t); } }
1,113,450
public TeamMember readTeamRel(final Long artifactId, final Long userId);
public Set<User> readTeamRel(final Long artifactId) throws HypersonicException;
1,113,451
public Color getBackground(final int index) { final Color color; Integer containerIndex = model.indexOfContainerPanel(container); if (isSelectedContainer()) { color = Colors.Browser.List.LIST_SELECTION_BG; } else { color = Colors.Browser.List.LIST_EXPANDED_NOT_SELECTED_BG; } leftJPanel.setBackground(color); rightJPanel.setBackground(color); return color; }
public Color getBackground(final int index) { final Color color; if (isSelectedContainer()) { color = Colors.Browser.List.LIST_SELECTION_BG; } else { color = Colors.Browser.List.LIST_EXPANDED_NOT_SELECTED_BG; } leftJPanel.setBackground(color); rightJPanel.setBackground(color); return color; }
1,113,452
void reloadHistoryList() { getPlatform().getAvatarRegistry().get(AvatarId.DOCUMENT_HISTORY3).reload(); }
void reloadHistoryList() { final Avatar avatar = getPlatform().getAvatarRegistry().get(AvatarId.DOCUMENT_HISTORY3); if(null != avatar) { avatar.reload(); } }
1,113,453
protected void installListeners(final DefaultTabPanel tabPanel, final javax.swing.JLabel iconJLabel) { iconJLabel.addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); if (e.getButton() == MouseEvent.BUTTON1) { if (cell.isActionAvailable()) { cell.invokeAction(); } } } public void mouseEntered(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.HAND_CURSOR); } } public void mouseExited(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.DEFAULT_CURSOR); } } }); addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); maybeShowPopup(e); } public void mouseReleased(final java.awt.event.MouseEvent e) { maybeShowPopup(e); } }); }
protected void installListeners(final DefaultTabPanel tabPanel, final javax.swing.JLabel iconJLabel) { iconJLabel.addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); if (e.getButton() == MouseEvent.BUTTON1) { if (cell.isActionAvailable()) { cell.invokeAction(); } } } public void mouseEntered(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.HAND_CURSOR); } } public void mouseExited(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.DEFAULT_CURSOR); } } }); addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); maybeShowPopup(e); } public void mouseReleased(final java.awt.event.MouseEvent e) { maybeShowPopup(e); } }); }
1,113,454
protected void installListeners(final DefaultTabPanel tabPanel, final javax.swing.JLabel iconJLabel) { iconJLabel.addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); if (e.getButton() == MouseEvent.BUTTON1) { if (cell.isActionAvailable()) { cell.invokeAction(); } } } public void mouseEntered(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.HAND_CURSOR); } } public void mouseExited(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.DEFAULT_CURSOR); } } }); addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); maybeShowPopup(e); } public void mouseReleased(final java.awt.event.MouseEvent e) { maybeShowPopup(e); } }); }
protected void installListeners(final DefaultTabPanel tabPanel, final javax.swing.JLabel iconJLabel) { iconJLabel.addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, Boolean.FALSE, e); if (e.getButton() == MouseEvent.BUTTON1) { if (cell.isActionAvailable()) { cell.invokeAction(); } } } public void mouseEntered(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.HAND_CURSOR); } } public void mouseExited(final java.awt.event.MouseEvent e) { if (cell.isActionAvailable()) { SwingUtil.setCursor(DefaultCellRenderer.this, java.awt.Cursor.DEFAULT_CURSOR); } } }); addMouseListener(new java.awt.event.MouseAdapter() { public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, Boolean.FALSE, e); maybeShowPopup(e); } public void mouseReleased(final java.awt.event.MouseEvent e) { maybeShowPopup(e); } }); }
1,113,455
public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); if (e.getButton() == MouseEvent.BUTTON1) { if (cell.isActionAvailable()) { cell.invokeAction(); } } }
public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); if (e.getButton() == MouseEvent.BUTTON1) { if (cell.isActionAvailable()) { cell.invokeAction(); } } }
1,113,456
public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, e); maybeShowPopup(e); }
public void mousePressed(final java.awt.event.MouseEvent e) { tabPanel.panelCellMousePressed(cell, Boolean.FALSE, e); maybeShowPopup(e); }
1,113,457
public void panelCellMousePressed(final Cell cell, final java.awt.event.MouseEvent e) { }
public void panelCellMousePressed(final Cell cell, final Boolean onIcon, final java.awt.event.MouseEvent e) { }
1,113,458
public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandleDraftCreatedIQ query = new HandleDraftCreatedIQ(); Boolean isComplete = Boolean.FALSE; while (Boolean.FALSE == isComplete) { if (isStartTag("uniqueId")) { query.uniqueId = readUniqueId2(); } else if (isStartTag("createdBy")) { query.createdBy = readJabberId2(); } else if (isStartTag("createdOn")) { query.createdOn = readCalendar2(); } else { isComplete = Boolean.TRUE; } } return query; }
public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandleDraftCreatedIQ query = new HandleDraftCreatedIQ(); Boolean isComplete = Boolean.FALSE; while (Boolean.FALSE == isComplete) { if (isStartTag("uniqueId")) { query.uniqueId = readUniqueId2(); } else if (isStartTag("createdBy")) { query.createdBy = readJabberId2(); } else if (isStartTag("createdOn")) { query.createdOn = readCalendar2(); } else { isComplete = Boolean.TRUE; } } return query; }
1,113,459
public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandleDraftCreatedIQ query = new HandleDraftCreatedIQ(); Boolean isComplete = Boolean.FALSE; while (Boolean.FALSE == isComplete) { if (isStartTag("uniqueId")) { query.uniqueId = readUniqueId2(); } else if (isStartTag("createdBy")) { query.createdBy = readJabberId2(); } else if (isStartTag("createdOn")) { query.createdOn = readCalendar2(); } else { isComplete = Boolean.TRUE; } } return query; }
public IQ parseIQ(final XmlPullParser parser) throws Exception { setParser2(parser); final HandleDraftCreatedIQ query = new HandleDraftCreatedIQ(); Boolean isComplete = Boolean.FALSE; while (Boolean.FALSE == isComplete) { if (isStartTag("uniqueId")) { query.uniqueId = readUniqueId2(); } else if (isStartTag("createdBy")) { query.createdBy = readJabberId2(); } else if (isStartTag("createdOn")) { query.createdOn = readCalendar2(); } else { isComplete = true; } } return query; }
1,113,460
public MainTitleAvatarTabPanel() { super(); this.allTabs = new HashMap<TabId, Tab>(); this.pluginTabs = new HashMap<PluginExtension, Tab>(); initComponents(); this.resizer = new Resizer(getBrowser(), containerJLabel, Boolean.FALSE, Resizer.ResizeEdges.LEFT); }
public MainTitleAvatarTabPanel() { super(); this.allTabs = new HashMap<TabId, Tab>(); this.pluginTabs = new HashMap<PluginExtension, Tab>(); initComponents(); this.resizer = new Resizer(getBrowser(), this, Boolean.TRUE, Resizer.ResizeEdges.LEFT); this.containerJLabelResizer = new Resizer(getBrowser(), containerJLabel, Boolean.FALSE, Resizer.ResizeEdges.LEFT); }
1,113,461
public static JLabel create(final Icon icon) { synchronized (singletonLock) { return singleton.doCreate(icon); } }
public static JLabel create() { synchronized (singletonLock) { return singleton.doCreate(icon); } }
1,113,462
public static JLabel create(final Icon icon) { synchronized (singletonLock) { return singleton.doCreate(icon); } }
public static JLabel create(final Icon icon) { synchronized (singletonLock) { return singleton.doCreate(); } }
1,113,463
BrowserMainDocumentModel(final Browser browser) { super(); this.browser = browser; this.documentFilter = new FilterChain<Artifact>(); this.documents = new LinkedList<MainCellDocument>(); this.history = new LinkedList<MainCellHistoryItem>(); this.jListModel = new DefaultListModel(); this.logger = browser.getPlatform().getLogger(getClass()); this.touchedDocuments = new LinkedList<MainCellDocument>(); this.visibleDocuments = new LinkedList<MainCellDocument>(); }
BrowserMainDocumentModel(final Browser browser) { super(); this.browser = browser; this.documentFilter = new FilterChain<Artifact>(); this.documents = new LinkedList<MainCellDocument>(); this.visibleHistory = new Hashtable<MainCellDocument, List<MainCellHistoryItem>>(10, 0.65F); this.jListModel = new DefaultListModel(); this.logger = browser.getPlatform().getLogger(getClass()); this.touchedDocuments = new LinkedList<MainCellDocument>(); this.visibleDocuments = new LinkedList<MainCellDocument>(); }
1,113,465
private void collapse(final MainCellDocument mcd) { mcd.setExpanded(Boolean.FALSE); MainCellHistoryItem mchi; for(final Iterator<MainCellHistoryItem> i = history.iterator(); i.hasNext();) { mchi = i.next(); if(mchi.getDocument().equals(mcd)) { i.remove(); } } }
private void collapse(final MainCellDocument mcd) { mcd.setExpanded(Boolean.FALSE); MainCellHistoryItem mchi; for(final Iterator<MainCellHistoryItem> i = visibleHistory.get(mcd).iterator(); i.hasNext();) { mchi = i.next(); if(mchi.getDocument().equals(mcd)) { i.remove(); } } }
1,113,466
void debug() { if(browser.getPlatform().isDebugMode()) { // documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + documents.size() + " DOCUMENTS]"); for(final MainCellDocument mcd : documents) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // visible documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + visibleDocuments.size() + " VISIBLE DOCUMENTS]"); for(final MainCellDocument mcd : visibleDocuments) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // history items logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + history.size() + " HISTORY ITEMS]"); for(final MainCellHistoryItem mchi : history) { logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mchi.getText() + "]"); } logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + jListModel.size() + " LIST CELLS]"); final Enumeration e = jListModel.elements(); while(e.hasMoreElements()) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + ((MainCell) e.nextElement()).getText() + "]"); documentFilter.debug(logger); } }
void debug() { if(browser.getPlatform().isDebugMode()) { // documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + documents.size() + " DOCUMENTS]"); for(final MainCellDocument mcd : documents) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // visible documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + visibleDocuments.size() + " VISIBLE DOCUMENTS]"); for(final MainCellDocument mcd : visibleDocuments) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // history items logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + history.size() + " HISTORY ITEMS]"); for(final MainCellHistoryItem mchi : history) { logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mchi.getText() + "]"); } logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + jListModel.size() + " LIST CELLS]"); final Enumeration e = jListModel.elements(); while(e.hasMoreElements()) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + ((MainCell) e.nextElement()).getText() + "]"); documentFilter.debug(logger); } }
1,113,467
void debug() { if(browser.getPlatform().isDebugMode()) { // documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + documents.size() + " DOCUMENTS]"); for(final MainCellDocument mcd : documents) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // visible documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + visibleDocuments.size() + " VISIBLE DOCUMENTS]"); for(final MainCellDocument mcd : visibleDocuments) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // history items logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + history.size() + " HISTORY ITEMS]"); for(final MainCellHistoryItem mchi : history) { logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mchi.getText() + "]"); } logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + jListModel.size() + " LIST CELLS]"); final Enumeration e = jListModel.elements(); while(e.hasMoreElements()) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + ((MainCell) e.nextElement()).getText() + "]"); documentFilter.debug(logger); } }
void debug() { if(browser.getPlatform().isDebugMode()) { // documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + documents.size() + " DOCUMENTS]"); for(final MainCellDocument mcd : documents) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // visible documents logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + visibleDocuments.size() + " VISIBLE DOCUMENTS]"); for(final MainCellDocument mcd : visibleDocuments) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mcd.getText() + "]"); // history items logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + history.size() + " HISTORY ITEMS]"); for(final MainCellHistoryItem mchi : history) { logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + mchi.getText() + "]"); } logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + jListModel.size() + " LIST CELLS]"); final Enumeration e = jListModel.elements(); while(e.hasMoreElements()) logger.debug("[BROWSER2] [APP] [B2] [MAIN MODEL] [" + ((MainCell) e.nextElement()).getText() + "]"); documentFilter.debug(logger); } }
1,113,468
private void expand(final MainCellDocument mcd) { mcd.setExpanded(Boolean.TRUE); final MainCellHistoryItem[] mchiArray = (MainCellHistoryItem[]) contentProvider.getElements(1, mcd); for(final MainCellHistoryItem mchi : mchiArray) { history.add(mchi); } }
private void expand(final MainCellDocument mcd) { mcd.setExpanded(Boolean.TRUE); final MainCellHistoryItem[] mchiArray = (MainCellHistoryItem[]) contentProvider.getElements(1, mcd); final List<MainCellHistoryItem> lmchi = visibleHistory.containsKey(mcd) ? visibleHistory.get(mcd) : new LinkedList<MainCellHistoryItem>(); for(final MainCellHistoryItem mchi : mchiArray) { lmchi.add(mchi); } visibleHistory.put(mcd, lmchi); }
1,113,469
public void trigger(final Browser application, final JPopupMenu jPopupMenu, final MouseEvent e) { if(historyItem.isSetVersionId()) { jPopupMenu.add(new OpenVersion(application)); if(!historyItem.getDocument().isClosed()) { final Set<User> team = historyItem.getDocumentTeam(); if(0 < team.size()) { final JMenu jMenu = MenuFactory.create(getString("SendVersion")); for(final User teamMember : team) { jMenu.add(new Send(application, teamMember)); } jPopupMenu.add(jMenu); } } } }
public void trigger(final Browser application, final JPopupMenu jPopupMenu, final MouseEvent e) { if(historyItem.isSetVersionId()) { jPopupMenu.add(new OpenVersion(application)); if(!historyItem.getDocument().isClosed()) { final Set<User> team = historyItem.getDocumentTeam(); if(0 < team.size()) { final JMenu jMenu = MenuFactory.create(getString("SendVersion")); for(final User teamMember : team) jMenu.add(new Send(application, teamMember)); } jPopupMenu.add(jMenu); } } } }
1,113,471
public void trigger(final Browser application, final JPopupMenu jPopupMenu, final MouseEvent e) { if(historyItem.isSetVersionId()) { jPopupMenu.add(new OpenVersion(application)); if(!historyItem.getDocument().isClosed()) { final Set<User> team = historyItem.getDocumentTeam(); if(0 < team.size()) { final JMenu jMenu = MenuFactory.create(getString("SendVersion")); for(final User teamMember : team) { jMenu.add(new Send(application, teamMember)); } jPopupMenu.add(jMenu); } } } }
public void trigger(final Browser application, final JPopupMenu jPopupMenu, final MouseEvent e) { if(historyItem.isSetVersionId()) { jPopupMenu.add(new OpenVersion(application)); if(!historyItem.getDocument().isClosed()) { final Set<User> team = historyItem.getDocumentTeam(); if(0 < team.size()) { final JMenu jMenu = MenuFactory.create(getString("SendVersion")); for(final User teamMember : team) { jMenu.add(new Send(application, teamMember)); jPopupMenu.add(jMenu);
1,113,472
void open(final String title, final Avatar avatar) { getRootPane().setBorder(new WindowBorder()); setTitle(title); add(avatar); pack(); avatar.reload(); avatar.setRoundCorners(Boolean.TRUE); setLocation(calculateLocation()); roundCorners(); setVisible(true); }
void open(final String title, final Avatar avatar) { getRootPane().setBorder(new WindowBorder()); setTitle(title); add(avatar); pack(); avatar.reload(); setLocation(calculateLocation()); roundCorners(); setVisible(true); }
1,113,473
void open(final String title, final Avatar avatar) { getRootPane().setBorder(new WindowBorder()); setTitle(title); add(avatar); pack(); avatar.reload(); avatar.setRoundCorners(Boolean.TRUE); setLocation(calculateLocation()); roundCorners(); setVisible(true); }
void open(final String title, final Avatar avatar) { getRootPane().setBorder(new WindowBorder()); setTitle(title); add(avatar); pack(); avatar.reload(); avatar.setRoundCorners(Boolean.TRUE); setLocation(calculateLocation()); new NativeSkin().roundCorners(this); setVisible(true); }
1,113,474
private Map<DocumentVersion, Delta> readDocumentVersionsWithDelta(final Long containerId, final Long versionId) { return ((ContainerProvider) contentProvider).readDocumentVersionsWithDelta( containerId, versionId); }
private Map<DocumentVersion, Delta> readDocumentVersionsWithDelta(final Long containerId, final Long versionId) { return ((ContainerProvider) contentProvider).readDocumentVersionDeltas( containerId, versionId); }
1,113,477
public PopupDocument(final MainCellDocument document) { super(); this.document = document; this.l18n = new PopupL18n("DocumentListItem"); }
public PopupDocument(final MainCellDocument document, final Connection connection) { super(); this.document = document; this.l18n = new PopupL18n("DocumentListItem"); }
1,113,478
public void trigger(final Browser application, final JPopupMenu jPopupMenu, final MouseEvent e) { if(document.isUrgent()) { final List<KeyRequest> keyRequests = document.getKeyRequests(); if(keyRequests.size() >= 1) { final Set<JabberId> requestedBySet = new HashSet<JabberId>(); for(final KeyRequest keyRequest : keyRequests) { // if a single user has requested more than once; we only // display one menu item. if(!requestedBySet.contains(keyRequest.getRequestedBy())) { jPopupMenu.add(new AcceptKeyRequest(application, keyRequest.getId(), keyRequest.getRequestedByName())); requestedBySet.add(keyRequest.getRequestedBy()); } } jPopupMenu.addSeparator(); jPopupMenu.add(new DeclineAllKeyRequests(application)); } } jPopupMenu.add(new Open(application)); if(document.isClosed()) { jPopupMenu.addSeparator(); jPopupMenu.add(new Delete(application)); } else { jPopupMenu.add(new Send(application)); if(document.isKeyHolder()) { jPopupMenu.addSeparator(); jPopupMenu.add(new Close(application)); } else { jPopupMenu.add(new RequestKey(application)); jPopupMenu.addSeparator(); jPopupMenu.add(new Delete(application)); } } // DEBUG Document Menu Options if(e.isShiftDown()) { final Clipboard systemClipboard = Toolkit.getDefaultToolkit().getSystemClipboard(); final ActionListener debugActionListener = new ActionListener() { public void actionPerformed(final ActionEvent e) { final StringSelection stringSelection = new StringSelection(((JComponent) e.getSource()).getClientProperty("COPY_ME").toString()); systemClipboard.setContents(stringSelection, null); } }; final JMenuItem idJMenuItem = new JMenuItem("Id - " + document.getId()); idJMenuItem.putClientProperty("COPY_ME", document.getId()); idJMenuItem.addActionListener(debugActionListener); final JMenuItem uidJMenuItem = new JMenuItem("Unique id - " + document.getUniqueId()); uidJMenuItem.putClientProperty("COPY_ME", document.getUniqueId()); uidJMenuItem.addActionListener(debugActionListener); jPopupMenu.addSeparator(); jPopupMenu.add(idJMenuItem); jPopupMenu.add(uidJMenuItem); } }
public void trigger(final Browser application, final JPopupMenu jPopupMenu, final MouseEvent e) { if(document.isUrgent()) { final List<KeyRequest> keyRequests = document.getKeyRequests(); if(keyRequests.size() >= 1) { final Set<JabberId> requestedBySet = new HashSet<JabberId>(); for(final KeyRequest keyRequest : keyRequests) { // if a single user has requested more than once; we only // display one menu item. if(!requestedBySet.contains(keyRequest.getRequestedBy())) { jPopupMenu.add(new AcceptKeyRequest(application, keyRequest.getId(), keyRequest.getRequestedByName())); requestedBySet.add(keyRequest.getRequestedBy()); } } jPopupMenu.addSeparator(); jPopupMenu.add(new DeclineAllKeyRequests(application)); } } jPopupMenu.add(new Open(application)); if(document.isClosed()) { jPopupMenu.addSeparator(); jPopupMenu.add(new Delete(application)); } else { jPopupMenu.add(new Send(application)); if(document.isKeyHolder()) { jPopupMenu.addSeparator(); jPopupMenu.add(new Close(application)); } else { jPopupMenu.add(new RequestKey(application)); jPopupMenu.addSeparator(); jPopupMenu.add(new Delete(application)); } } // DEBUG Document Menu Options if(e.isShiftDown()) { final Clipboard systemClipboard = Toolkit.getDefaultToolkit().getSystemClipboard(); final ActionListener debugActionListener = new ActionListener() { public void actionPerformed(final ActionEvent e) { final StringSelection stringSelection = new StringSelection(((JComponent) e.getSource()).getClientProperty("COPY_ME").toString()); systemClipboard.setContents(stringSelection, null); } }; final JMenuItem idJMenuItem = new JMenuItem("Id - " + document.getId()); idJMenuItem.putClientProperty("COPY_ME", document.getId()); idJMenuItem.addActionListener(debugActionListener); final JMenuItem uidJMenuItem = new JMenuItem("Unique id - " + document.getUniqueId()); uidJMenuItem.putClientProperty("COPY_ME", document.getUniqueId()); uidJMenuItem.addActionListener(debugActionListener); jPopupMenu.addSeparator(); jPopupMenu.add(idJMenuItem); jPopupMenu.add(uidJMenuItem); } }
1,113,480
public void actionPerformed(final ActionEvent e) { application.runLogin(); }
public void actionPerformed(final ActionEvent e) { application.runLogin(); }
1,113,482
public void actionPerformed(final ActionEvent e) { application.runLogout(); }
public void actionPerformed(final ActionEvent e) { application.runLogout(); }
1,113,483
public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}));
public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}));
1,113,484
public void actionPerformed(final ActionEvent e) { application.displayAbout(); }
public void actionPerformed(final ActionEvent e) { application.displayAbout(); }
1,113,485
public void actionPerformed(ActionEvent e) { application.runExitPlatform(); }
public void actionPerformed(ActionEvent e) { application.runExitPlatform(); }
1,113,486
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container.getId()); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
1,113,487
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container.getId()); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
1,113,488
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container.getId()); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
1,113,489
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
protected void setUp() throws Exception { super.setUp(); login(OpheliaTestUser.JUNIT); login(OpheliaTestUser.JUNIT_X); final InternalContainerModel containerModel = getContainerModel(OpheliaTestUser.JUNIT); final Container container = createContainer(OpheliaTestUser.JUNIT, NAME); final List<Document> documents = addDocuments(OpheliaTestUser.JUNIT, container); publishToContacts(OpheliaTestUser.JUNIT, container); createDraft(OpheliaTestUser.JUNIT, container); // remove half of the documents for (int i = 0; i < documents.size(); i++) { if (1 == i % 2) containerModel.removeDocument(container.getId(), documents.get(i).getId()); } publishToTeam(OpheliaTestUser.JUNIT, container); // re-add half of the documents createDraft(OpheliaTestUser.JUNIT_X, container); final File[] inputFiles = getInputFiles(); for (int i = 0; i < inputFiles.length; i++) { if (1 == i % 2) { addDocument(OpheliaTestUser.JUNIT, container, inputFiles[i]); } } publishToTeam(OpheliaTestUser.JUNIT_X, container.getId()); final ContainerVersion version = containerModel.readLatestVersion(container.getId()); datum = new Fixture(container, containerModel, getOutputDirectory(), version); containerModel.addListener(datum); }
1,113,490
static void notifyArtifactClosed(final UUID artifactUniqueId, final JabberId artifactClosedBy) { try { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); iDModel.close(artifactUniqueId, artifactClosedBy); } catch(final ParityException px) { sLogger.fatal("Could not close artifact.", px); return; } }
static void notifyArtifactClosed(final UUID artifactUniqueId, final JabberId artifactClosedBy) { try { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); iDModel.close(artifactUniqueId, artifactClosedBy); } catch(final ParityException px) { sLogger.fatal("Could not close artifact.", px); return; } }
1,113,491
static void notifyDocumentReceived(final XMPPDocument xmppDocument) { try { DocumentModel.getInternalModel(sContext).receive(xmppDocument); } catch(ParityException px) { sLogger.fatal("Could not receive document.", px); return; } }
static void notifyDocumentReceived(final XMPPDocument xmppDocument) { try { DocumentModel.getInternalModel(sContext).receive(xmppDocument); } catch(ParityException px) { sLogger.fatal("Could not receive document.", px); return; } }
1,113,492
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) throws SmackException, ParityException { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
1,113,493
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
1,113,494
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
1,113,495
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
static void notifyKeyRequestAccepted(final UUID artifactUniqueId, final JabberId acceptedBy) { final InternalDocumentModel iDModel = DocumentModel.getInternalModel(sContext); try { final Document document = iDModel.get(artifactUniqueId); iDModel.unlock(document.getId()); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.TRUE, acceptedBy); // audit receive key final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } iDModel.auditRecieveKey(document.getId(), loggedInUser.getId(), currentDateTime(), acceptedBy); } catch(final SmackException sx) { sLogger.fatal("Could not accept key request.", sx); return; } catch(ParityException px) { sLogger.fatal("Could not accept key request.", px); return; } }
1,113,496
static void notifyKeyRequestDenied(final UUID artifactUniqueId, final JabberId deniedBy) { try { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.FALSE, deniedBy); } catch(final ParityException px) { sLogger.error("Could not accept key response denial.", px); return; } }
static void notifyKeyRequestDenied(final UUID artifactUniqueId, final JabberId deniedBy) { try { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext). createKeyResponse(document.getId(), Boolean.FALSE, deniedBy); } catch(final ParityException px) { sLogger.error("Could not accept key response denial.", px); return; } }
1,113,497
static void notifyKeyRequested(final UUID artifactUniqueId, final JabberId requestedBy) { try { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext).createKeyRequest(document.getId(), requestedBy); // audit key request final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } sAuditor.requestKey(document.getId(), loggedInUser.getId(), currentDateTime(), requestedBy, loggedInUser.getId()); } catch(final SmackException sx) { sLogger.fatal("Could not process key request: " + artifactUniqueId, sx); return; } catch(final ParityException px) { sLogger.error("Could not process key request: " + artifactUniqueId, px); return; } }
static void notifyKeyRequested(final UUID artifactUniqueId, final JabberId requestedBy) { try { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext).createKeyRequest(document.getId(), requestedBy); // audit key request final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } sAuditor.requestKey(document.getId(), loggedInUser.getId(), currentDateTime(), requestedBy, loggedInUser.getId()); } catch(final SmackException sx) { sLogger.fatal("Could not process key request: " + artifactUniqueId, sx); return; } catch(final ParityException px) { sLogger.error("Could not process key request: " + artifactUniqueId, px); return; } }
1,113,498
static void notifyKeyRequested(final UUID artifactUniqueId, final JabberId requestedBy) { try { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext).createKeyRequest(document.getId(), requestedBy); // audit key request final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } sAuditor.requestKey(document.getId(), loggedInUser.getId(), currentDateTime(), requestedBy, loggedInUser.getId()); } catch(final SmackException sx) { sLogger.fatal("Could not process key request: " + artifactUniqueId, sx); return; } catch(final ParityException px) { sLogger.error("Could not process key request: " + artifactUniqueId, px); return; } }
static void notifyKeyRequested(final UUID artifactUniqueId, final JabberId requestedBy) { try { final Document document = DocumentModel.getInternalModel(sContext).get(artifactUniqueId); SystemMessageModel.getInternalModel(sContext).createKeyRequest(document.getId(), requestedBy); // audit key request final User loggedInUser; synchronized(xmppHelperLock) { loggedInUser = xmppHelper.getUser(); } sAuditor.requestKey(document.getId(), loggedInUser.getId(), currentDateTime(), requestedBy, loggedInUser.getId()); } catch(final SmackException sx) { sLogger.fatal("Could not process key request: " + artifactUniqueId, sx); return; } catch(final ParityException px) { sLogger.error("Could not process key request: " + artifactUniqueId, px); return; } }
1,113,499
protected InternalDocumentModel getInternalDocumentModel() { return DocumentModel.getInternalModel(getContext(), workspace); }
protected InternalDocumentModel getInternalDocumentModel() { return DocumentModel.getInternalModel(getContext(), workspace); };
1,113,500
protected InternalDownloadModel getInternalDownloadModel() { return DownloadModel.getInternalModel(getContext(), workspace); };
protected InternalDownloadModel getInternalDownloadModel() { return DownloadModel.getInternalModel(getContext(), workspace); }
1,113,501
protected final void logVariable(final String name, final Object value) { if(logger.isDebugEnabled()) { logger.debug(MessageFormat.format("{0} {1}:{2}", null == workspace ? "null" : workspace.getWorkspaceDirectory().getName(), name, Log4JHelper.render(logger, value))); } }
protected final void logVariable(final String name, final Object value) { if(logger.isDebugEnabled()) { logger.debug(MessageFormat.format("{0} {1}:{2}", null == workspace ? NO_WORKSPACE : workspace.getWorkspaceDirectory().getName(), name, Log4JHelper.render(logger, value))); } }
1,113,502
private Avatar createDocumentHistory3List() { final Avatar a = new DocumentHistoryAvatar3(); a.setContentProvider(ProviderFactory.getHistoryProvider()); return a; }
private Avatar createDocumentHistory3List() { final Avatar a = new HistoryItems(); a.setContentProvider(ProviderFactory.getHistoryProvider()); return a; }
1,113,503
private Avatar doCreate(final AvatarId id) { final Avatar avatar; switch(id) { case BROWSER_INFO: avatar = createBrowserInfo(); break; case BROWSER_MAIN: avatar = createBrowserMain(); break; case BROWSER_TITLE: avatar = createBrowserTitle(); break; case DOCUMENT_HISTORY3: avatar = createDocumentHistory3List(); break; case PLATFORM_LOGIN: avatar = createPlatformLogin(); break; case SESSION_INVITE_PARTNER: avatar = createSessionInvitePartner(); break; case SESSION_MANAGE_CONTACTS: avatar = createSessionManageContacts(); break; case SESSION_SEND_FORM: avatar = createSessionSendForm(); break; case SESSION_SEND_KEY_FORM: avatar = createSessionSendKeyForm(); break; default: throw Assert.createUnreachable("Unknown avatar: " + id); } register(avatar); return avatar; }
private Avatar doCreate(final AvatarId id) { final Avatar avatar; switch(id) { case BROWSER_INFO: avatar = createBrowserInfo(); break; case BROWSER_MAIN: avatar = createBrowserMain(); break; case BROWSER_TITLE: avatar = createBrowserTitle(); break; case DOCUMENT_HISTORY3: avatar = createDocumentHistory3List(); break; case PLATFORM_LOGIN: avatar = createPlatformLogin(); break; case SESSION_INVITE_PARTNER: avatar = createSessionInvitePartner(); break; case SESSION_MANAGE_CONTACTS: avatar = createSessionManageContacts(); break; case SESSION_SEND_FORM: avatar = createSessionSendForm(); break; case SESSION_SEND_KEY_FORM: avatar = createSessionSendKeyForm(); break; default: throw Assert.createUnreachable("Unknown avatar: " + id); } register(avatar); return avatar; }
1,113,504
private void initComponents() { dateJLabel = LabelFactory.create(BrowserConstants.SmallFont); eventJLabel = LabelFactory.create(BrowserConstants.SmallFont); versionJLabel = LabelFactory.create(BrowserConstants.SmallFont); final GridBagConstraints c = new GridBagConstraints(); c.insets.left = 7; c.anchor = GridBagConstraints.WEST; add(dateJLabel, c.clone()); c.insets.left = 0; add(versionJLabel, c.clone()); c.weightx = 1; add(eventJLabel, c.clone()); }
private void initComponents() { dateJLabel = LabelFactory.create(BrowserConstants.SmallFont); eventJLabel = LabelFactory.create(BrowserConstants.SmallFont); versionJLabel = LabelFactory.create(BrowserConstants.SmallFont); final GridBagConstraints c = new GridBagConstraints(); c.insets.left = 7; c.anchor = GridBagConstraints.WEST; add(dateJLabel, c.clone()); c.insets.left = 0; add(versionJLabel, c.clone()); c.weightx = 1; add(eventJLabel, c.clone()); }
1,113,505
private void initComponents() { dateJLabel = LabelFactory.create(BrowserConstants.SmallFont); eventJLabel = LabelFactory.create(BrowserConstants.SmallFont); versionJLabel = LabelFactory.create(BrowserConstants.SmallFont); final GridBagConstraints c = new GridBagConstraints(); c.insets.left = 7; c.anchor = GridBagConstraints.WEST; add(dateJLabel, c.clone()); c.insets.left = 0; add(versionJLabel, c.clone()); c.weightx = 1; add(eventJLabel, c.clone()); }
private void initComponents() { dateJLabel = LabelFactory.create(BrowserConstants.SmallFont); eventJLabel = LabelFactory.create(BrowserConstants.SmallFont); versionJLabel = LabelFactory.create(BrowserConstants.SmallFont); final GridBagConstraints c = new GridBagConstraints(); c.insets.left = 7; c.anchor = GridBagConstraints.WEST; add(dateJLabel, c.clone()); c.insets.left = 0; add(versionJLabel, c.clone()); c.weightx = 1; add(eventJLabel, c.clone()); }
1,113,506
public String getBundleURIToScriptsFolder(){ if(rootScriptsFolderBundleURI == null){ IWBundle iwb = this.getBundle(); rootScriptsFolderBundleURI = iwb.getResourcesPath()+"javascript/"; } return rootScriptsFolderBundleURI; }
public String getBundleURIToScriptsFolder(){ if(rootScriptsFolderBundleURI == null){ IWBundle iwb = this.getBundle(); rootScriptsFolderBundleURI = iwb.getResourcesVirtualPath()+"/javascript/"; } return rootScriptsFolderBundleURI; }
1,113,507
protected void setUp() throws Exception { super.setUp(); final DocumentModel documentModel = getDocumentModel(OpheliaTestUser.JUNIT); final File inputFile = getInputFiles()[0]; final Document document = createDocument(OpheliaTestUser.JUNIT, inputFile); modifyDocument(OpheliaTestUser.JUNIT, document); datum = new Fixture(document, documentModel); documentModel.addListener(datum); }
protected void setUp() throws Exception { super.setUp(); final DocumentModel documentModel = getDocumentModel(OpheliaTestUser.JUNIT); final File inputFile = getInputFiles()[0]; final Document document = createDocument(OpheliaTestUser.JUNIT, inputFile); modifyDocument(OpheliaTestUser.JUNIT, document.getId()); datum = new Fixture(document, documentModel); documentModel.addListener(datum); }
1,113,508
public Boolean confirm(final String confirmMessageKey) { return ConfirmDialog.confirm(mainWindow, confirmMessageKey); }
public Boolean confirm(final String confirmMessageKey) { return ConfirmDialog.confirm(mainWindow, confirmMessageKey); }
1,113,510
private Boolean didConfirm() { return confirm; }
public Boolean didConfirm() { return confirm; }
1,113,511
public void run() { LOGGER.logApiId(); LOGGER.logVariable("streamId", streamId); LOGGER.logVariable("streamId", streamOffset); LOGGER.logVariable("streamId", streamSize); try { final InputStream input = streamServer.openInputStream(streamSession, streamId, streamOffset); int len; long total = streamOffset.longValue(); final byte[] b = new byte[streamSession.getBufferSize()]; try { while((len = input.read(b)) > 0) { LOGGER.logDebug("Downstream sent: {0}/{1}", total += len, streamSize); output.write(b, 0, len); output.flush(); } } finally { input.close(); output.flush(); output.close(); } } catch (final IOException iox) { throw new StreamException(iox); } }
public void run() { LOGGER.logApiId(); LOGGER.logVariable("streamId", streamId); LOGGER.logVariable("streamId", streamOffset); LOGGER.logVariable("streamId", streamSize); try { final InputStream input = streamServer.openInputStream(streamSession, streamId, streamOffset); int len; long total = streamOffset.longValue(); final byte[] b = new byte[streamSession.getBufferSize()]; try { while((len = input.read(b)) > 0) { LOGGER.logDebug("Downstream sent: {0}/{1}", total += len, streamSize); output.write(b, 0, len); output.flush(); } } finally { input.close(); output.flush(); output.close(); } } catch (final IOException iox) { throw new StreamException(iox); } }
1,113,512
public ServletLogger( ServletContext sc ) { servletContext = sc; }
public ServletLogger() { servletContext = sc; }
1,113,513
public ServletLogger( ServletContext sc ) { servletContext = sc; }
public ServletLogger( ServletContext sc ) { }
1,113,514
private CreationListener createDocumentModelCreationListener() { return new CreationListener() { public void objectCreated(final CreationEvent e) {} public void objectReceived(final CreationEvent e) { controller.reloadMainBrowserAvatar(); } public void objectVersionCreated(final VersionCreationEvent e) { controller.reloadMainBrowserAvatar(); } public void objectVersionReceived(VersionCreationEvent e) {} }; }
private CreationListener createDocumentModelCreationListener() { return new CreationListener() { public void objectCreated(final CreationEvent e) {} public void objectReceived(final CreationEvent e) { controller.reloadMainBrowserAvatar(); } public void objectVersionCreated(final VersionCreationEvent e) { controller.reloadMainBrowserAvatar(); } public void objectVersionReceived(final VersionCreationEvent e) { controller.reloadMainBrowserAvatar(); } }; }
1,113,516
public void objectVersionReceived(VersionCreationEvent e) {}
public void objectVersionReceived(final VersionCreationEvent e) { controller.reloadMainBrowserAvatar(); }
1,113,517
private UpdateListener createDocumentModelUpdateListener() { return new UpdateListener() { public void objectDeleted(final DeleteEvent e) { controller.reloadMainBrowserAvatar(); } public void objectReceived(final UpdateEvent e) {} public void objectUpdated(final UpdateEvent e) { controller.reloadMainBrowserAvatar(); } }; }
private UpdateListener createDocumentModelUpdateListener() { return new UpdateListener() { public void objectDeleted(final DeleteEvent e) { controller.reloadMainBrowserAvatar(); } public void objectReceived(final UpdateEvent e) { controller.reloadMainBrowserAvatar(); } public void objectUpdated(final UpdateEvent e) { controller.reloadMainBrowserAvatar(); } }; }
1,113,518
public void objectReceived(final UpdateEvent e) {}
public void objectReceived(final UpdateEvent e) { controller.reloadMainBrowserAvatar(); }
1,113,519
private KeyListener createSessionModelKeyListener() { return new KeyListener() { public void keyRequestAccepted(final KeyEvent e) {} public void keyRequestDenied(final KeyEvent e) {} public void keyRequested(final KeyEvent e) {} }; }
private KeyListener createSessionModelKeyListener() { return new KeyListener() { public void keyRequestAccepted(final KeyEvent e) {} public void keyRequestDenied(final KeyEvent e) {} public void keyRequested(final KeyEvent e) {} }; }
1,113,520
public void keyRequestAccepted(final KeyEvent e) {}
public void keyRequestAccepted(final KeyEvent e) { controller.reloadMainBrowserAvatar(); }
1,113,521
public void keyRequestDenied(final KeyEvent e) {}
public void keyRequestDenied(final KeyEvent e) { controller.reloadMainBrowserAvatar(); }
1,113,522
public void keyRequested(final KeyEvent e) {}
public void keyRequested(final KeyEvent e) { controller.reloadMainBrowserAvatar(); }
1,113,523
private PresenceListener createSessionModelPresenceListener() { return new PresenceListener() { public void presenceRequested(final PresenceEvent e) {} }; }
private PresenceListener createSessionModelPresenceListener() { return new PresenceListener() { public void presenceRequested(final PresenceEvent e) { controller.reloadMainBrowserAvatar(); } }; }
1,113,524
public void presenceRequested(final PresenceEvent e) {}
public void presenceRequested(final PresenceEvent e) { controller.reloadMainBrowserAvatar(); }
1,113,525
public void addListener(final PresenceListener presenceListener) { synchronized(implLock) { impl.addListener(presenceListener); } }
public void addListener(final PresenceListener presenceListener) { synchronized(implLock) { impl.addListener(presenceListener); } }
1,113,526
public void mouseClicked(java.awt.event.MouseEvent evt) { rightJPanelMouseClicked(evt); }
public void mouseClicked(java.awt.event.MouseEvent evt) { leftJPanelMouseClicked(evt); }
1,113,529
public void mousePressed(java.awt.event.MouseEvent evt) { rightJPanelMousePressed(evt); }
public void mousePressed(java.awt.event.MouseEvent evt) { leftJPanelMousePressed(evt); }
1,113,530
public void prepareForRepaint() { // Set background colour final Color color = getBackgroundColor(); leftJPanel.setBackground(color); rightJPanel.setBackground(color); // Make sure the split pane remains in a 50/50 split if (versionsJSplitPane.getSize().getWidth() > 0 ){ versionsJSplitPane.setDividerLocation(0.5); } }
public void prepareForRepaint() { // Set background colour final Color color = getBackgroundColor(); leftJPanel.setBackground(color); rightJPanel.setBackground(color); // Make sure the split pane remains in a 50/50 split if (versionsJSplitPane.getSize().getWidth() > 0 ){ versionsJSplitPane.setDividerLocation(0.5); } }
1,113,531
TrayMenuBuilder(final SystemApplication application) { super(); this.application = application; this.browser = new AbstractAction(getString("Menu.Browser")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}; this.browser.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.BrowserMnemonic").charAt(0))); if(application.isDevelopmentMode()) { this.restart = new AbstractAction(getString("Menu.Restart")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestartPlatform(); } }; this.restart.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.RestartMnemonic").charAt(0))); } else { this.restart = null; } this.exit = new AbstractAction(getString("Menu.Exit")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runExitPlatform(); }}; this.exit.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.ExitMnemonic").charAt(0))); }
TrayMenuBuilder(final SystemApplication application) { super(); this.application = application; this.browser = new AbstractAction(getString("Menu.Browser")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}; this.browser.putValue(Action.MNEMONIC_KEY, Integer.valueOf(getString("Menu.BrowserMnemonic").charAt(0))); if(application.isDevelopmentMode()) { this.restart = new AbstractAction(getString("Menu.Restart")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestartPlatform(); } }; this.restart.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.RestartMnemonic").charAt(0))); } else { this.restart = null; } this.exit = new AbstractAction(getString("Menu.Exit")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runExitPlatform(); }}; this.exit.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.ExitMnemonic").charAt(0))); }
1,113,532
TrayMenuBuilder(final SystemApplication application) { super(); this.application = application; this.browser = new AbstractAction(getString("Menu.Browser")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}; this.browser.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.BrowserMnemonic").charAt(0))); if(application.isDevelopmentMode()) { this.restart = new AbstractAction(getString("Menu.Restart")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestartPlatform(); } }; this.restart.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.RestartMnemonic").charAt(0))); } else { this.restart = null; } this.exit = new AbstractAction(getString("Menu.Exit")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runExitPlatform(); }}; this.exit.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.ExitMnemonic").charAt(0))); }
TrayMenuBuilder(final SystemApplication application) { super(); this.application = application; this.browser = new AbstractAction(getString("Menu.Browser")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}; this.browser.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.BrowserMnemonic").charAt(0))); if(application.isDevelopmentMode()) { this.restart = new AbstractAction(getString("Menu.Restart")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestartPlatform(); } }; this.restart.putValue(Action.MNEMONIC_KEY, Integer.valueOf(getString("Menu.RestartMnemonic").charAt(0))); } else { this.restart = null; } this.exit = new AbstractAction(getString("Menu.Exit")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runExitPlatform(); }}; this.exit.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.ExitMnemonic").charAt(0))); }
1,113,533
TrayMenuBuilder(final SystemApplication application) { super(); this.application = application; this.browser = new AbstractAction(getString("Menu.Browser")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}; this.browser.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.BrowserMnemonic").charAt(0))); if(application.isDevelopmentMode()) { this.restart = new AbstractAction(getString("Menu.Restart")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestartPlatform(); } }; this.restart.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.RestartMnemonic").charAt(0))); } else { this.restart = null; } this.exit = new AbstractAction(getString("Menu.Exit")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runExitPlatform(); }}; this.exit.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.ExitMnemonic").charAt(0))); }
TrayMenuBuilder(final SystemApplication application) { super(); this.application = application; this.browser = new AbstractAction(getString("Menu.Browser")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestoreBrowser(); }}; this.browser.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.BrowserMnemonic").charAt(0))); if(application.isDevelopmentMode()) { this.restart = new AbstractAction(getString("Menu.Restart")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runRestartPlatform(); } }; this.restart.putValue(Action.MNEMONIC_KEY, new Integer(getString("Menu.RestartMnemonic").charAt(0))); } else { this.restart = null; } this.exit = new AbstractAction(getString("Menu.Exit")) { private static final long serialVersionUID = 1; public void actionPerformed(final ActionEvent e) { application.runExitPlatform(); }}; this.exit.putValue(Action.MNEMONIC_KEY, Integer.valueOf(getString("Menu.ExitMnemonic").charAt(0))); }
1,113,534
public static ActionMessages getMessages(HttpServletRequest request) { return (ActionMessages)request.getAttribute(Globals.MESSAGE_KEY); }
public static ActionMessages getMessages(HttpServletRequest request) { ActionMessages messages = new ActionMessages(); HttpSession session = request.getSession(false); if (session != null) { ActionMessages sessionMessages = (ActionMessages)session.getAttribute(Globals.MESSAGE_KEY); if (sessionMessages != null) { messages.add(sessionMessages); } } ActionMessages requestMessages = (ActionMessages)request.getAttribute(Globals.MESSAGE_KEY); if (requestMessages != null) { messages.add(requestMessages); } return messages; }
1,113,535
ContainerVersion extractVersion(final Session session) { final ContainerVersion version = new ContainerVersion(); version.setArtifactId(session.getLong("CONTAINER_ID")); version.setArtifactType(session.getTypeFromInteger("ARTIFACT_TYPE_ID")); version.setArtifactUniqueId(session.getUniqueId("ARTIFACT_UNIQUE_ID")); version.setCreatedBy(session.getString("CREATED_BY")); version.setCreatedOn(session.getCalendar("CREATED_ON")); version.setName(session.getString("ARTIFACT_NAME")); version.setUpdatedBy(session.getString("UPDATED_BY")); version.setUpdatedOn(session.getCalendar("UPDATED_ON")); version.setVersionId(session.getLong("CONTAINER_VERSION_ID")); version.setMetaData(artifactIO.getVersionMetaData(session, version.getArtifactId(), version.getVersionId())); return version; }
ContainerVersion extractVersion(final Session session) { final ContainerVersion version = new ContainerVersion(); version.setArtifactId(session.getLong("CONTAINER_ID")); version.setArtifactType(session.getTypeFromInteger("ARTIFACT_TYPE_ID")); version.setArtifactUniqueId(session.getUniqueId("ARTIFACT_UNIQUE_ID")); version.setCreatedBy(session.getString("CREATED_BY")); version.setCreatedOn(session.getCalendar("CREATED_ON")); version.setName(session.getString("ARTIFACT_NAME")); version.setUpdatedBy(session.getString("UPDATED_BY")); version.setUpdatedOn(session.getCalendar("UPDATED_ON")); version.setVersionId(session.getLong("CONTAINER_VERSION_ID")); version.setMetaData(getVersionMetaData(version.getArtifactId(), version.getVersionId())); return version; }
1,113,536