bugged
stringlengths 6
599k
| fixed
stringlengths 10
599k
| __index_level_0__
int64 0
1.13M
|
|---|---|---|
private JMenuItem getOpenMenuItem() { if(null == openMenuItem) { openMenuItem = createJMenuItem(getString("Open"), getMnemonic("OpenMnemonic"), getOpenMenuItemActionListener()); } return openMenuItem; }
|
private JMenuItem getOpenMenuItem() { if(null == openMenuItem) { openMenuItem = createJMenuItem(getString("Open"), getMnemonic("Open"), getOpenMenuItemActionListener()); } return openMenuItem; }
| 1,113,079
|
private JMenuItem getRequestKeyMenuItem() { if(null == requestKeyMenuItem) { requestKeyMenuItem = createJMenuItem(getString("RequestKey"), getMnemonic("RequestKeyMnemonic"), getRequestKeyMenuItemActionListener()); } return requestKeyMenuItem; }
|
private JMenuItem getRequestKeyMenuItem() { if(null == requestKeyMenuItem) { requestKeyMenuItem = createJMenuItem(getString("RequestKey"), getMnemonic("RequestKey"), getRequestKeyMenuItemActionListener()); } return requestKeyMenuItem; }
| 1,113,080
|
private JMenuItem getSendKeyMenuItem() { if(null == sendKeyMenuItem) { sendKeyMenuItem = createJMenuItem(getString("SendKey"), getMnemonic("SendKeyMnemonic"), getSendKeyMenuItemActionListener()); } return sendKeyMenuItem; }
|
private JMenuItem getSendKeyMenuItem() { if(null == sendKeyMenuItem) { sendKeyMenuItem = createJMenuItem(getString("SendKey"), getMnemonic("SendKey"), getSendKeyMenuItemActionListener()); } return sendKeyMenuItem; }
| 1,113,081
|
private JMenuItem getSendMenuItem() { if(null == sendMenuItem) { sendMenuItem = createJMenuItem(getString("Send"), getMnemonic("SendMnemonic"), getSendMenuItemActionListener()); } return sendMenuItem; }
|
private JMenuItem getSendMenuItem() { if(null == sendMenuItem) { sendMenuItem = createJMenuItem(getString("Send"), getMnemonic("Send"), getSendMenuItemActionListener()); } return sendMenuItem; }
| 1,113,082
|
SystemMessageModelImpl(final Workspace workspace) { super(workspace, L18nContext.SYSTEM_MESSAGE); this.defaultComparator = new ComparatorBuilder().createSystemMessageDefault(); this.systemMessageIO = IOFactory.getDefault().createSystemMessageHandler(); }
|
SystemMessageModelImpl(final Workspace workspace) { super(workspace); this.defaultComparator = new ComparatorBuilder().createSystemMessageDefault(); this.systemMessageIO = IOFactory.getDefault().createSystemMessageHandler(); }
| 1,113,085
|
protected String getString(final String localKey, final Object[] arguments) { return l18n.getString(localKey, arguments); }
|
protected String getString(final String localKey, final Object[] arguments) { return l18n.getString(localKey, arguments); }
| 1,113,086
|
Session(final SessionManager sessionManager, final Connection connection) { super(); this.connection = connection; this.logger = new Log4JWrapper(); this.id = JVMUniqueId.nextId(); this.sessionManager = sessionManager; }
|
Session(final SessionManager sessionManager, final Connection connection) { super(); this.connection = connection; this.id = JVMUniqueId.nextId(); this.sessionManager = sessionManager; }
| 1,113,087
|
public void execute(final String sql) { assertOpen("execute(String)"); logger.logVariable("sql", sql); try { final Statement s = connection.createStatement(); s.execute(sql); commit(); } catch(final SQLException sqlx) { rollback(); throw new HypersonicException(sqlx); } }
|
public void execute(final String sql) { assertOpen("execute(String)"); logger.logVariable("sql", sql); try { final Statement s = connection.createStatement(); s.execute(sql); commit(); } catch(final SQLException sqlx) { rollback(); throw new HypersonicException(sqlx); } }
| 1,113,088
|
public AuditEventType getAuditEventTypeFromInteger(final String columnName) { assertOpen("getAuditEventTypeFromInteger(String)"); assertOpenResult("getAuditEventTypeFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : AuditEventType.fromId(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public AuditEventType getAuditEventTypeFromInteger(final String columnName) { assertOpen("getAuditEventTypeFromInteger(String)"); assertOpenResult("getAuditEventTypeFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : AuditEventType.fromId(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,089
|
public Boolean getBoolean(final String columnName) { assertOpen("[GET BOOLEAN]"); assertOpenResult("[GET BOOLEAN]"); logger.logVariable("columnName", columnName); try { final Boolean value = resultSet.getBoolean(columnName); return resultSet.wasNull() ? null : value; } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public Boolean getBoolean(final String columnName) { assertOpen("[GET BOOLEAN]"); assertOpenResult("[GET BOOLEAN]"); logger.logVariable("columnName", columnName); try { final Boolean value = resultSet.getBoolean(columnName); return resultSet.wasNull() ? null : value; } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,091
|
public byte[] getBytes(final String columnName) { assertOpen("getBytes(String)"); assertOpenResult("getBytes(String)"); try { final byte[] value = resultSet.getBytes(columnName); return resultSet.wasNull() ? null : value; } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public byte[] getBytes(final String columnName) { assertOpen("getBytes(String)"); assertOpenResult("getBytes(String)"); try { final byte[] value = resultSet.getBytes(columnName); return resultSet.wasNull() ? null : value; } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,093
|
public EMail getEMail(final String columnName) { assertOpen("getCalendar(String)"); assertOpenResult("getCalendar(String)"); try { final String value = resultSet.getString(columnName); if (resultSet.wasNull()) { return null; } else { return EMailBuilder.parse(value); } } catch (final EMailFormatException efx) { throw new HypersonicException(efx); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public EMail getEMail(final String columnName) { assertOpen("getCalendar(String)"); assertOpenResult("getCalendar(String)"); try { final String value = resultSet.getString(columnName); if (resultSet.wasNull()) { return null; } else { return EMailBuilder.parse(value); } } catch (final EMailFormatException efx) { throw new HypersonicException(efx); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,095
|
public EMail getEMail(final String columnName) { assertOpen("getCalendar(String)"); assertOpenResult("getCalendar(String)"); try { final String value = resultSet.getString(columnName); if (resultSet.wasNull()) { return null; } else { return EMailBuilder.parse(value); } } catch (final EMailFormatException efx) { throw new HypersonicException(efx); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public EMail getEMail(final String columnName) { assertOpen("getCalendar(String)"); assertOpenResult("getCalendar(String)"); try { final String value = resultSet.getString(columnName); if (resultSet.wasNull()) { return null; } else { return EMailBuilder.parse(value); } } catch (final EMailFormatException efx) { throw new HypersonicException(efx); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,096
|
public ArtifactFlag getFlagFromInteger(final String columnName) { assertOpen("getFlagFromInteger(String)"); assertOpenResult("getFlagFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : ArtifactFlag.fromId(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public ArtifactFlag getFlagFromInteger(final String columnName) { assertOpen("getFlagFromInteger(String)"); assertOpenResult("getFlagFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : ArtifactFlag.fromId(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,097
|
public ArtifactFlag getFlagFromString(final String columnName) { assertOpen("getFlagFromString(String)"); assertOpenResult("getFlagFromString(String)"); logger.logVariable("columnName", columnName); try { final String value = resultSet.getString(columnName); return resultSet.wasNull() ? null : ArtifactFlag.valueOf(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public ArtifactFlag getFlagFromString(final String columnName) { assertOpen("getFlagFromString(String)"); assertOpenResult("getFlagFromString(String)"); logger.logVariable("columnName", columnName); try { final String value = resultSet.getString(columnName); return resultSet.wasNull() ? null : ArtifactFlag.valueOf(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,099
|
public InputStream getInputStream(final String columnName) { assertOpen("[GET INPUT STREAM]"); assertOpenResult("[GET INPUT STREAM]"); logger.logVariable("columnName", columnName); try { final InputStream value = resultSet.getBinaryStream(columnName); return resultSet.wasNull() ? null : value; } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public InputStream getInputStream(final String columnName) { assertOpen("[GET INPUT STREAM]"); assertOpenResult("[GET INPUT STREAM]"); logger.logVariable("columnName", columnName); try { final InputStream value = resultSet.getBinaryStream(columnName); return resultSet.wasNull() ? null : value; } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,101
|
public void getMetaDataTables() { assertOpen(); assertMetaData(); try { resultSet = metaData.getTables(null, "PUBLIC", null, new String[] {"TABLE"}); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void getMetaDataTables() { assertOpen(); assertMetaData(); try { resultSet = metaData.getTables(null, "PUBLIC", null, new String[] {"TABLE"}); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,103
|
public MetaDataType getMetaDataTypeFromInteger(final String columnName) { assertOpen("getMetaDataTypeFromInteger(String)"); assertOpenResult("getMetaDataTypeFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : MetaDataType.fromId(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public MetaDataType getMetaDataTypeFromInteger(final String columnName) { assertOpen("getMetaDataTypeFromInteger(String)"); assertOpenResult("getMetaDataTypeFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : MetaDataType.fromId(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,104
|
public ArtifactState getStateFromString(final String columnName) { assertOpen("getStateFromString(String)"); assertOpenResult("getStateFromString(String)"); logger.logVariable("columnName", columnName); try { final String value = resultSet.getString(columnName); return resultSet.wasNull() ? null : ArtifactState.valueOf(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public ArtifactState getStateFromString(final String columnName) { assertOpen("getStateFromString(String)"); assertOpenResult("getStateFromString(String)"); logger.logVariable("columnName", columnName); try { final String value = resultSet.getString(columnName); return resultSet.wasNull() ? null : ArtifactState.valueOf(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,106
|
public SystemMessageType getSystemMessageTypeFromInteger( final String columnName) { assertOpen("getSystemMessageTypeFromInteger(String)"); assertOpenResult("getSystemMessageTypeFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : SystemMessageType.fromId(value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public SystemMessageType getSystemMessageTypeFromInteger( final String columnName) { assertOpen("getSystemMessageTypeFromInteger(String)"); assertOpenResult("getSystemMessageTypeFromInteger(String)"); logger.logVariable("columnName", columnName); try { final Integer value = resultSet.getInt(columnName); return resultSet.wasNull() ? null : SystemMessageType.fromId(value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,108
|
public ArtifactType getTypeFromString(final String columnName) { assertOpen("getTypeFromString(String)"); assertOpenResult("getTypeFromString(String)"); logger.logVariable("columnName", columnName); try { final String value = resultSet.getString(columnName); return resultSet.wasNull() ? null : ArtifactType.valueOf(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public ArtifactType getTypeFromString(final String columnName) { assertOpen("getTypeFromString(String)"); assertOpenResult("getTypeFromString(String)"); logger.logVariable("columnName", columnName); try { final String value = resultSet.getString(columnName); return resultSet.wasNull() ? null : ArtifactType.valueOf(value); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,110
|
public void openMetaData() { assertOpen("getMetaData"); try { metaData = connection.getMetaData(); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void openMetaData() { assertConnectionIsOpen(); try { metaData = connection.getMetaData(); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,112
|
public void setBoolean(final Integer index, final Boolean value) { assertOpen("setBoolean(Integer,Boolean)"); assertPreparedStatement("setBoolean(Integer,Boolean)"); logIndexAndValue(index, value); try { preparedStatement.setBoolean(index, value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setBoolean(final Integer index, final Boolean value) { assertOpen("setBoolean(Integer,Boolean)"); assertPreparedStatement("setBoolean(Integer,Boolean)"); logIndexAndValue(index, value); try { preparedStatement.setBoolean(index, value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,113
|
public void setBytes(final Integer index, final byte[] value) { assertOpen("setBytes(Integer,Byte[])"); assertPreparedStatement("setBytes(Integer,Byte[])"); logIndexAndValue(index, value); try { preparedStatement.setBytes(index, value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setBytes(final Integer index, final byte[] value) { assertOpen("setBytes(Integer,Byte[])"); assertPreparedStatement("setBytes(Integer,Byte[])"); logIndexAndValue(index, value); try { preparedStatement.setBytes(index, value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,114
|
public void setEMail(final Integer index, final EMail value) { assertOpen("setEMail(Integer,EMail)"); assertPreparedStatement("setEMail(Integer,EMail)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setEMail(final Integer index, final EMail value) { assertOpen("setEMail(Integer,EMail)"); assertPreparedStatement("setEMail(Integer,EMail)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,115
|
public void setFlagAsInteger(final Integer index, final ArtifactFlag value) { assertOpen("setFlagAsInteger(Integer,ArtifactFlag)"); assertPreparedStatement("setFlagAsInteger(Integer,ArtifactFlag)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value.getId()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setFlagAsInteger(final Integer index, final ArtifactFlag value) { assertOpen("setFlagAsInteger(Integer,ArtifactFlag)"); assertPreparedStatement("setFlagAsInteger(Integer,ArtifactFlag)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value.getId()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,116
|
public void setFlagAsString(final Integer index, final ArtifactFlag value) { assertOpen("setFlagAsString(Integer,ArtifactFlag)"); assertPreparedStatement("setFlagAsString(Integer,ArtifactFlag)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setFlagAsString(final Integer index, final ArtifactFlag value) { assertOpen("setFlagAsString(Integer,ArtifactFlag)"); assertPreparedStatement("setFlagAsString(Integer,ArtifactFlag)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,117
|
public void setInt(final Integer index, final Integer value) { assertOpen("setInt(Integer,Integer)"); assertPreparedStatement("setInt(Integer,Integer)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setInt(final Integer index, final Integer value) { assertOpen("setInt(Integer,Integer)"); assertPreparedStatement("setInt(Integer,Integer)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,118
|
public void setMetaDataAsString(final Integer index, final MetaData value) { assertOpen("setMetaDataAsString(Integer,MetaData)"); assertPreparedStatement("setMetaDataAsString(Integer,MetaData)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setMetaDataAsString(final Integer index, final MetaData value) { assertOpen("setMetaDataAsString(Integer,MetaData)"); assertPreparedStatement("setMetaDataAsString(Integer,MetaData)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,119
|
public void setQualifiedUsername(final Integer index, final JabberId value) { assertOpen("Database session is not open."); assertPreparedStatement("Prepared statement has not been set."); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.getQualifiedUsername()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setQualifiedUsername(final Integer index, final JabberId value) { assertOpen("Database session is not open."); assertPreparedStatement("Prepared statement has not been set."); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.getQualifiedUsername()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,120
|
public void setStateAsInteger(final Integer index, final ArtifactState value) { assertOpen("setStateAsInteger(Integer,ArtifactState)"); assertPreparedStatement("setStateAsInteger(Integer,ArtifactState)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value.getId()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setStateAsInteger(final Integer index, final ArtifactState value) { assertOpen("setStateAsInteger(Integer,ArtifactState)"); assertPreparedStatement("setStateAsInteger(Integer,ArtifactState)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value.getId()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,121
|
public void setStateAsString(final Integer index, final ArtifactState value) { assertOpen("setStateAsString(Integer,ArtifactState)"); assertPreparedStatement("setStateAsString(Integer,ArtifactState)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setStateAsString(final Integer index, final ArtifactState value) { assertOpen("setStateAsString(Integer,ArtifactState)"); assertPreparedStatement("setStateAsString(Integer,ArtifactState)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,122
|
public void setStream(final Integer index, final InputStream stream, final Integer streamLength) { assertOpen(""); assertPreparedStatement(""); try { preparedStatement.setBinaryStream(index, stream, streamLength); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setStream(final Integer index, final InputStream stream, final Integer streamLength) { assertOpen(""); assertPreparedStatement(""); try { preparedStatement.setBinaryStream(index, stream, streamLength); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,123
|
public void setStream(final Integer index, final InputStream stream, final Integer streamLength) { assertOpen(""); assertPreparedStatement(""); try { preparedStatement.setBinaryStream(index, stream, streamLength); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setStream(final Integer index, final InputStream stream, final Integer streamLength) { assertOpen(""); assertPreparedStatement(""); try { preparedStatement.setBinaryStream(index, value, valueLength); } catch (final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,124
|
public void setTypeAsInteger(final Integer index, final ArtifactType value) { assertOpen("setTypeAsInteger(Integer,ArtifactType)"); assertPreparedStatement("setTypeAsInteger(Integer,ArtifactType)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value.getId()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setTypeAsInteger(final Integer index, final ArtifactType value) { assertOpen("setTypeAsInteger(Integer,ArtifactType)"); assertPreparedStatement("setTypeAsInteger(Integer,ArtifactType)"); logIndexAndValue(index, value); try { preparedStatement.setInt(index, value.getId()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,125
|
public void setTypeAsString(final Integer index, final ArtifactType value) { assertOpen("setTypeAsString(Integer,ArtifactType)"); assertPreparedStatement("setTypeString(Integer,ArtifactType)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setTypeAsString(final Integer index, final ArtifactType value) { assertOpen("setTypeAsString(Integer,ArtifactType)"); assertPreparedStatement("setTypeString(Integer,ArtifactType)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,126
|
public void setUniqueId(final Integer index, final UUID value) { assertOpen("setUniqueId(Integer,UUID)"); assertPreparedStatement("setUniqueId(Integer,UUID)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
|
public void setUniqueId(final Integer index, final UUID value) { assertOpen("setUniqueId(Integer,UUID)"); assertPreparedStatement("setUniqueId(Integer,UUID)"); logIndexAndValue(index, value); try { preparedStatement.setString(index, value.toString()); } catch(final SQLException sqlx) { throw new HypersonicException(sqlx); } }
| 1,113,127
|
public XMPPMethodResponse execute(final XMPPConnection xmppConnection) { // add an executed on parameter setParameter(Xml.All.EXECUTED_ON, DateUtil.getInstance()); // create a collector for the response final PacketCollector idCollector = createPacketCollector(xmppConnection); // send the internet query logVariable("preSendPacket", DateUtil.getInstance()); xmppConnection.sendPacket(this); logVariable("postSendPacket", DateUtil.getInstance()); // this sleep has been inserted because when packets are sent within // x milliseconds of each other, they tend to get swallowed by the // smack library try { Thread.sleep(75); } catch(final InterruptedException ix) {} // the timeout is used because the timeout is not expected to be long; // and it helps debug non-implemented responses logVariable("preResponseCollected", DateUtil.getInstance()); try { return (XMPPMethodResponse) idCollector.nextResult(); } catch (final ClassCastException ccx) { final String errorId = new ErrorHelper().getErrorId(ccx); logger.logError(errorId, ccx); logger.logError("name:{0}", name); logger.logError("xmppConnection:{0}", xmppConnection); throw new XMPPException(errorId); } finally { // re-set the parameters post execution logVariable("postResponseCollected", DateUtil.getInstance()); parameters.clear(); } }
|
public XMPPMethodResponse execute(final XMPPConnection xmppConnection) { // add an executed on parameter setParameter(Xml.All.EXECUTED_ON, DateUtil.getInstance()); // create a collector for the response final PacketCollector idCollector = createPacketCollector(xmppConnection); // send the internet query logVariable("preSendPacket", DateUtil.getInstance()); xmppConnection.sendPacket(this); logVariable("postSendPacket", DateUtil.getInstance()); // this sleep has been inserted because when packets are sent within // x milliseconds of each other, they tend to get swallowed by the // smack library try { Thread.sleep(75); } catch(final InterruptedException ix) {} // the timeout is used because the timeout is not expected to be long; // and it helps debug non-implemented responses logVariable("preResponseCollected", DateUtil.getInstance()); try { return (XMPPMethodResponse) idCollector.nextResult(3 * 1000); } catch (final ClassCastException ccx) { final String errorId = new ErrorHelper().getErrorId(ccx); logger.logError(errorId, ccx); logger.logError("name:{0}", name); logger.logError("xmppConnection:{0}", xmppConnection); throw new XMPPException(errorId); } finally { // re-set the parameters post execution logVariable("postResponseCollected", DateUtil.getInstance()); parameters.clear(); } }
| 1,113,128
|
protected LinkTool copyWith(String uri) { LinkTool copy = duplicate(); copy.uri = uri; return copy; }
|
protected LinkTool copyWith(QueryPair pair) { LinkTool copy = duplicate(); copy.uri = uri; return copy; }
| 1,113,129
|
protected LinkTool copyWith(String uri) { LinkTool copy = duplicate(); copy.uri = uri; return copy; }
|
protected LinkTool copyWith(String uri) { LinkTool copy = duplicate(); if (copy.queryData != null) { copy.queryData = (ArrayList)this.queryData.clone(); } else { copy.queryData = new ArrayList(); } copy.queryData.add(pair); return copy; }
| 1,113,130
|
public List<DocumentVersion> readArchiveDocumentVersions( final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId);
|
public List<DocumentVersion> readArchiveDocumentVersions( final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId);
| 1,113,133
|
public List<DocumentVersion> readBackupDocumentVersions( final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId);
|
public List<DocumentVersion> readBackupDocumentVersions( final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId);
| 1,113,134
|
void initialize(final StreamSession session, final String streamId) { authenticate(session); fileServer.initialize(session, streamId); socketServer.initialize(session, streamId); }
|
void initialize(final StreamSession session, final String streamId) { authenticate(session); fileServer.initialize(session, streamId); socketServer.initialize(session, streamId); }
| 1,113,135
|
void destroy(final StreamSession session, final String streamId) { authenticate(session); fileServer.destroy(session, streamId); socketServer.destroy(session, streamId); }
|
void destroy(final StreamSession session) { authenticate(session); fileServer.destroy(session, streamId); socketServer.destroy(session, streamId); }
| 1,113,136
|
void destroy(final StreamSession session, final String streamId) { authenticate(session); fileServer.destroy(session, streamId); socketServer.destroy(session, streamId); }
|
void destroy(final StreamSession session, final String streamId) { authenticate(session); fileServer.destroy(session, streamId); socketServer.destroy(session, streamId); }
| 1,113,137
|
public void fireSelection() { getController().selectDocument(getDocumentId()); getController().displayDocumentHistoryListAvatar(); }
|
public void fireSelection() { getController().selectDocument(getDocumentId()); getController().displayDocumentHistoryAvatar(); }
| 1,113,138
|
<T extends XMPPEvent> void handleEvent(final T xmppEvent) { logger.pushContext(new Log4JContext() { public String getContext() { return xmppCore.getUserId().getUsername(); } }); logger.logVariable("xmppEvent", xmppEvent); final List<XMPPEventListener<T>> listeners = getListeners(xmppEvent.getClass()); for (final XMPPEventListener<T> listener : listeners) { listener.handleEvent(xmppEvent); } logger.popContext(); }
|
<T extends XMPPEvent> void handleEvent(final T xmppEvent) { logger.pushContext(new Log4JContext() { public String getContext() { return xmppCore.getUserId().getUsername(); } }); logger.logVariable("xmppEvent", xmppEvent); final List<XMPPEventListener<T>> listeners = getListeners(xmppEvent.getClass()); for (final XMPPEventListener<T> listener : listeners) { try { listener.handleEvent(xmppEvent); } catch (final Throwable t) { logger.logFatal(t, "Could not handle xmpp event {0}.", xmppEvent); } } logger.popContext(); }
| 1,113,139
|
private void deleteProfiles(final FileSystem profileFileSystem) { final File[] profileDirectories = profileFileSystem.list("/", new FileFilter() { public boolean accept(final File pathname) { return pathname.getName().startsWith(displayName); } }, Boolean.FALSE); for (final File profileDirectorie : profileDirectories) { FileUtil.deleteTree(profileDirectorie); } }
|
private void deleteProfiles(final FileSystem profileFileSystem) { final File[] profileDirectories = profileFileSystem.list("/", new FileFilter() { public boolean accept(final File pathname) { return pathname.getName().startsWith(displayName); } }, Boolean.FALSE); for (final File profileDirectorie : profileDirectories) { FileUtil.deleteTree(profileDirectorie); } }
| 1,113,140
|
public Document(final String name, final Calendar createdOn, final String createdBy, final String keyHolder, final String description, final File directory, final UUID id, final byte[] content, final String contentChecksum) { super(null, name, description, createdOn, createdBy, keyHolder, id); this.directory = directory; this.content = content; this.contentChecksum = contentChecksum; this.versions = new Vector<DocumentVersion>(3); }
|
public Document(final String name, final Calendar createdOn, final String createdBy, final String keyHolder, final String description, final File directory, final UUID id, final byte[] content, final String contentChecksum) { super(null, name, description, createdOn, createdBy, id); this.directory = directory; this.content = content; this.contentChecksum = contentChecksum; this.versions = new Vector<DocumentVersion>(3); }
| 1,113,141
|
public File lookupXmlFile(final UUID id) { final String xmlFileAbsolutePath = idToXmlFileLookup.get(id.toString()); if(null == xmlFileAbsolutePath) { return null; } else { return new File(xmlFileAbsolutePath); } }
|
public File lookupXmlFile(final UUID id) { final String xmlFileAbsolutePath = idToXmlFileLookup.get(id.toString()); if(null == xmlFileAbsolutePath) { return null; } else { return new File(xmlFileAbsolutePath); } }
| 1,113,142
|
protected quickfix.Session getQuickFixSession(Session nettySession, Message message) { quickfix.Session quickfixSession = getQuickFixSession(nettySession); if (quickfixSession == null) { // No QF session for this Netty session, SessionID sessionID = getSessionID(message, true); quickfixSession = (quickfix.Session) quickfixSessions.get(sessionID); if (quickfixSession != null) { ResponderAdapter r = (ResponderAdapter) quickfixSession.getResponder(); if (r != null) { // QF session is bound to another Netty session. Not allowed. logError(nettySession, sessionID, "session with multiple connections not allowed", null); nettySession.close(); return null; } } } if (quickfixSession == null) { logError(nettySession, null, "unknown QF session ID", null); nettySession.close(); return null; } return quickfixSession; }
|
protected quickfix.Session getQuickFixSession(Session nettySession, Message message) { quickfix.Session quickfixSession = getQuickFixSession(nettySession); if (quickfixSession == null) { // No QF session for this Netty session, SessionID sessionID = getSessionID(message, true); quickfixSession = (quickfix.Session) quickfixSessions.get(sessionID); if (quickfixSession != null) { ResponderAdapter r = (ResponderAdapter) quickfixSession.getResponder(); if (r != null) { // QF session is bound to another Netty session. Not allowed. logError(nettySession, sessionID, "session with multiple connections not allowed", null); nettySession.close(); return null; } } } if (quickfixSession == null) { logError(nettySession, null, "unknown QF session ID", null); nettySession.close(); return null; } return quickfixSession; }
| 1,113,143
|
void index(final ArtifactIndex index) throws ParityException { logger.info("[LMODEL] [INDEX] [INDEX ARTIFACT]"); logger.debug(index); final InternalSessionModel iSModel = getInternalSessionModel(); final List<JabberId> jabberIds = new LinkedList<JabberId>(); jabberIds.add(index.getCreatedBy()); jabberIds.add(index.getKeyHolder()); jabberIds.addAll(index.getContacts()); final List<User> users = iSModel.readUsers(jabberIds); final List<User> contacts = filter(users, index.getContacts()); final User createdBy = filter(users, index.getKeyHolder()); final User keyHolder = filter(users, index.getCreatedBy()); final DocumentBuilder db = new DocumentBuilder(6); db.append(IDX_ARTIFACT_ID.setValue(index.getId()).toField()) .append(IDX_ARTIFACT_NAME.setValue(index.getName()).toField()) .append(IDX_ARTIFACT_CREATED_ON.setValue(index.getCreatedOn(), DateTools.Resolution.DAY).toField()) .append(IDX_ARTIFACT_CREATED_BY.setValue(createdBy).toField()) .append(IDX_ARTIFACT_KEYHOLDER.setValue(keyHolder).toField()) .append(IDX_ARTIFACT_CONTACTS.setValue(contacts).toField()); index(db.toDocument()); }
|
void index(final ArtifactIndex index) throws ParityException { logger.info("[LMODEL] [INDEX] [INDEX ARTIFACT]"); logger.debug(index); final InternalSessionModel iSModel = getInternalSessionModel(); final List<JabberId> jabberIds = new LinkedList<JabberId>(); jabberIds.add(index.getCreatedBy()); jabberIds.add(index.getKeyHolder()); jabberIds.addAll(index.getContacts()); final List<User> users = iSModel.readUsers(jabberIds); final List<User> contacts = filter(users, index.getContacts()); final User createdBy = filter(users, index.getKeyHolder()); final User keyHolder = filter(users, index.getCreatedBy()); final DocumentBuilder db = new DocumentBuilder(6); db.append(IDX_ARTIFACT_ID.setValue(index.getId()).toField()) .append(IDX_ARTIFACT_NAME.setValue(index.getName()).toField()) .append(IDX_ARTIFACT_CREATED_ON.setValue(index.getCreatedOn(), DateTools.Resolution.DAY).toField()) .append(IDX_ARTIFACT_CREATED_BY.setValue(createdBy).toField()) .append(IDX_ARTIFACT_KEYHOLDER.setValue(keyHolder).toField()) .append(IDX_ARTIFACT_CONTACTS.setValue(contacts).toField()); index(db.toDocument()); }
| 1,113,144
|
private IndexReader openIndexReader() throws ParityException { try { return IndexReader.open(workspace.getIndexDirectory()); } catch(final IOException iox) { logger.error("Could not open index.", iox); logger.error(workspace.getIndexDirectory()); throw ParityErrorTranslator.translate(iox); } }
|
private IndexReader openIndexReader() throws ParityException { try { return IndexReader.open(getIndexDirectory()); } catch(final IOException iox) { logger.error("Could not open index.", iox); logger.error(workspace.getIndexDirectory()); throw ParityErrorTranslator.translate(iox); } }
| 1,113,145
|
private IndexReader openIndexReader() throws ParityException { try { return IndexReader.open(workspace.getIndexDirectory()); } catch(final IOException iox) { logger.error("Could not open index.", iox); logger.error(workspace.getIndexDirectory()); throw ParityErrorTranslator.translate(iox); } }
|
private IndexReader openIndexReader() throws ParityException { try { return IndexReader.open(workspace.getIndexDirectory()); } catch(final IOException iox) { logger.error("Could not open index.", iox); logger.error(workspace.getIndexDirectory()); throw ParityErrorTranslator.translate(iox); } }
| 1,113,146
|
public FieldBuilder setValue(final Long l) { this.value = l.toString(); return this; }
|
public FieldBuilder setValue(final Long l) { this.value = l.toString(); return this; }
| 1,113,147
|
public List<QueryHit> search(final String expression) { final List<Query> queries = createQueries(expression); final List<QueryHit> hits = new LinkedList<QueryHit>(); final QueryHitBuilder queryHitBuilder = new QueryHitBuilder(idField); Iterator iHits; for(final Query query : queries) { logger.debug("query:" + query.toString()); try { iHits = indexSearcher.search(query).iterator(); } catch(final IOException iox) { throw new IndexException("Could not search index.", iox); } while(iHits.hasNext()) { hits.add(queryHitBuilder.toQueryHit((Hit) iHits.next())); } } return hits; }
|
public List<QueryHit> search(final String expression) { final List<Query> queries = createQueries(expression); final List<QueryHit> hits = new LinkedList<QueryHit>(); final QueryHitBuilder queryHitBuilder = new QueryHitBuilder(idField); Iterator iHits; for(final Query query : queries) { logger.info("[LMODEL] [INDEX] [SEARCH] [QUERY]"); logger.debug(query.toString()); try { iHits = indexSearcher.search(query).iterator(); } catch(final IOException iox) { throw new IndexException("Could not search index.", iox); } while(iHits.hasNext()) { hits.add(queryHitBuilder.toQueryHit((Hit) iHits.next())); } } return hits; }
| 1,113,148
|
public ExtensibleDialog (Frame parent, String title) { super(title); setFont(defaultBigFont); buttonPressed = new MesquiteInteger(1); prepareDialog(parent,title,buttonPressed); addWindowListener(this); }
|
public ExtensibleDialog (Frame parent, String title) { super(title); setFont(defaultBigFont); buttonPressed = new MesquiteInteger(1); prepareDialog(parent,title,buttonPressed); addWindowListener(this); }
| 1,113,149
|
public User create(final User user) { final Session session = openSession(); try { session.prepareStatement(SQL_CREATE); session.setQualifiedUsername(1, user.getId()); if(1 != session.executeUpdate()) throw new HypersonicException(""); final Long userId = session.getIdentity(); session.prepareStatement(SQL_CREATE_INFO); session.setLong(1, userId); session.setString(2, user.getFirstName()); session.setString(3, user.getLastName()); session.setString(4, user.getOrganization()); if(1 != session.executeUpdate()) throw new HypersonicException(""); user.setLocalId(userId); return user; } catch(final HypersonicException hx) { session.rollback(); throw hx; } finally { session.close(); } }
|
public void create(final User user) { final Session session = openSession(); try { session.prepareStatement(SQL_CREATE); session.setQualifiedUsername(1, user.getId()); if(1 != session.executeUpdate()) throw new HypersonicException(""); final Long userId = session.getIdentity(); session.prepareStatement(SQL_CREATE_INFO); session.setLong(1, userId); session.setString(2, user.getFirstName()); session.setString(3, user.getLastName()); session.setString(4, user.getOrganization()); if(1 != session.executeUpdate()) throw new HypersonicException(""); user.setLocalId(userId); return user; } catch(final HypersonicException hx) { session.rollback(); throw hx; } finally { session.close(); } }
| 1,113,150
|
public User create(final User user) { final Session session = openSession(); try { session.prepareStatement(SQL_CREATE); session.setQualifiedUsername(1, user.getId()); if(1 != session.executeUpdate()) throw new HypersonicException(""); final Long userId = session.getIdentity(); session.prepareStatement(SQL_CREATE_INFO); session.setLong(1, userId); session.setString(2, user.getFirstName()); session.setString(3, user.getLastName()); session.setString(4, user.getOrganization()); if(1 != session.executeUpdate()) throw new HypersonicException(""); user.setLocalId(userId); return user; } catch(final HypersonicException hx) { session.rollback(); throw hx; } finally { session.close(); } }
|
public User create(final User user) { final Session session = openSession(); try { session.prepareStatement(SQL_CREATE); session.setQualifiedUsername(1, user.getId()); if(1 != session.executeUpdate()) throw new HypersonicException(""); final Long userId = session.getIdentity(); session.prepareStatement(SQL_CREATE_INFO); session.setLong(1, userId); session.setString(2, user.getFirstName()); session.setString(3, user.getLastName()); session.setString(4, user.getOrganization()); if(1 != session.executeUpdate()) throw new HypersonicException(""); user.setLocalId(userId); session.commit(); } catch(final HypersonicException hx) { session.rollback(); throw hx; } finally { session.close(); } }
| 1,113,151
|
public User create(final User user);
|
public void create(final User user);
| 1,113,152
|
private void initComponents() { searchJTextField = TextFactory.create(); // COLOR SearchText 237,241,244,255 searchJTextField.setBackground(new Color(237, 241, 244, 255)); // BORDER SearchText TopBottom 204,215,226,255 searchJTextField.setBorder(new TopBottomBorder(new Color(204, 215, 226, 255))); searchJTextField.addActionListener(new ActionListener() { public void actionPerformed(final ActionEvent e) { searchJTextFieldActionPerformed(e); } }); searchJTextField.getDocument().addDocumentListener(new DocumentListener() { public void changedUpdate(final DocumentEvent e) { searchJTextFieldChangedUpdate(e); } public void insertUpdate(final DocumentEvent e) { searchJTextFieldInsertUpdate(e); } public void removeUpdate(final DocumentEvent e) { searchJTextFieldRemoveUpdate(e); } }); searchJTextField.setTransferHandler(new CreateDocumentTxHandler(getBrowser())); searchLeftJLabel = LabelFactory.create(SEARCH_LEFT_ICON); searchRightJLabel = LabelFactory.create(SEARCH_RIGHT_ICON); final GridBagConstraints c = new GridBagConstraints(); c.anchor = GridBagConstraints.EAST; c.insets.left = 275; add(searchLeftJLabel, c.clone()); c.anchor = GridBagConstraints.CENTER; c.fill = GridBagConstraints.BOTH; c.insets.left = 0; c.weightx = 1; add(searchJTextField, c.clone()); c.fill = GridBagConstraints.NONE; c.insets.left = 0; c.insets.right = 7; c.weightx = 0; add(searchRightJLabel, c.clone()); }
|
private void initComponents() { searchJTextField = TextFactory.create(); // COLOR SearchText 237,241,244,255 searchJTextField.setBackground(new Color(237, 241, 244, 255)); // BORDER SearchText TopBottom 204,215,226,255 searchJTextField.setBorder(new TopBottomBorder(new Color(204, 215, 226, 255))); searchJTextField.addActionListener(new ActionListener() { public void actionPerformed(final ActionEvent e) { searchJTextFieldActionPerformed(e); } }); searchJTextField.getDocument().addDocumentListener(new DocumentListener() { public void changedUpdate(final DocumentEvent e) { searchJTextFieldChangedUpdate(e); } public void insertUpdate(final DocumentEvent e) { searchJTextFieldInsertUpdate(e); } public void removeUpdate(final DocumentEvent e) { searchJTextFieldRemoveUpdate(e); } }); searchJTextField.setTransferHandler(new CreateDocumentTxHandler(getBrowser())); searchLeftJLabel = LabelFactory.create(SEARCH_LEFT_ICON); searchRightJLabel = LabelFactory.create(SEARCH_RIGHT_ICON); final GridBagConstraints c = new GridBagConstraints(); c.anchor = GridBagConstraints.EAST; c.insets.left = 329; add(searchLeftJLabel, c.clone()); c.anchor = GridBagConstraints.CENTER; c.fill = GridBagConstraints.BOTH; c.insets.left = 0; c.weightx = 1; add(searchJTextField, c.clone()); c.fill = GridBagConstraints.NONE; c.insets.left = 0; c.insets.right = 7; c.weightx = 0; add(searchRightJLabel, c.clone()); }
| 1,113,154
|
private void deleteLocal(final Long documentId) { final Document document = read(documentId); // delete audit final InternalAuditModel iAuditModel = getInternalAuditModel(); iAuditModel.delete(documentId); // delete versions final Collection<DocumentVersion> versions = listVersions(documentId); for(final DocumentVersion version : versions) { getLocalFile(document, version).delete(); documentIO.deleteVersion(version.getArtifactId(), version.getVersionId()); } // delete index getIndexModel().deleteDocument(documentId); // delete document final LocalFile localFile = getLocalFile(document); localFile.delete(); localFile.deleteParent(); documentIO.delete(documentId); }
|
private void deleteLocal(final Long documentId) { final Document document = read(documentId); // delete audit final InternalAuditModel iAuditModel = getInternalAuditModel(); iAuditModel.delete(documentId); // delete versions final Collection<DocumentVersion> versions = listVersions(documentId); for(final DocumentVersion version : versions) { getLocalFile(document, version).delete(); documentIO.deleteVersion(version.getArtifactId(), version.getVersionId()); } // delete index getIndexModel().deleteDocument(documentId); // delete document final LocalFile localFile = getLocalFile(document); localFile.delete(); localFile.deleteParent(); documentIO.delete(documentId); }
| 1,113,155
|
public Comparator<Artifact> createByName(final Boolean isAscending) { return new NameComparator(isAscending); }
|
public Comparator<Artifact> createByName(final Boolean isAscending) { return new NameComparator(isAscending); }
| 1,113,156
|
public static synchronized byte[] read( InputStream inputStream) throws IOException { return read(inputStream, DEFAULT_CHARSET_NAME); }
|
public static synchronized byte[] read( InputStream inputStream) throws IOException { return read(inputStream, DEFAULT_CHARSET_NAME); }
| 1,113,157
|
protected final File downloadStream(final String streamId) throws IOException { final File streamFile = workspace.createTempFile(streamId); final FileOutputStream stream = new FileOutputStream(streamFile); final StreamSession session = getSessionModel().createStreamSession(); final StreamReader reader = new StreamReader(session); reader.open(); try { reader.read(streamId, stream); } finally { try { stream.close(); } finally { reader.close(); } } return streamFile; }
|
protected final File downloadStream(final String streamId) throws IOException { final File streamFile = workspace.createTempFile(streamId); final FileOutputStream stream = new FileOutputStream(streamFile); final StreamSession session = getSessionModel().createStreamSession(); final StreamReader reader = new StreamReader(session); try { reader.read(streamId, stream); } finally { try { stream.close(); } finally { reader.close(); } } return streamFile; }
| 1,113,158
|
public Boolean doesVersionExist(final Long artifactId, final Long versionId) { synchronized (getImplLock()) { return getImpl().doesVersionExist(artifactId, versionId); } }
|
public Boolean doesVersionExist(final Long artifactId) { synchronized (getImplLock()) { return getImpl().doesVersionExist(artifactId, versionId); } }
| 1,113,160
|
public Boolean doesVersionExist(final Long artifactId, final Long versionId) { synchronized (getImplLock()) { return getImpl().doesVersionExist(artifactId, versionId); } }
|
public Boolean doesVersionExist(final Long artifactId, final Long versionId) { synchronized (getImplLock()) { return getImpl().doesVersionExist(artifactId); } }
| 1,113,161
|
public XMPPSessionImpl() { super(); this.listeners = new ArrayList<SessionListener>(); this.xmppArchive = new XMPPArchive(this); this.xmppBackup = new XMPPBackup(this); this.xmppArtifact = new XMPPArtifact(this); this.xmppContainer = new XMPPContainer(this); this.xmppContact = new XMPPContact(this); this.xmppProfile = new XMPPProfile(this); this.xmppStream = new XMPPStream(this); this.xmppSystem = new XMPPSystem(this); this.xmppUser = new XMPPUser(this); }
|
public XMPPSessionImpl() { super(); this.listeners = new ArrayList<SessionListener>(); this.xmppArchive = new XMPPArchive(this); this.xmppBackup = new XMPPBackup(this); this.xmppArtifact = new XMPPArtifact(this); this.xmppContainer = new XMPPContainer(this); this.xmppContact = new XMPPContact(this); this.xmppProfile = new XMPPProfile(this); this.xmppStream = new XMPPStream(this); this.xmppSystem = new XMPPSystem(this); this.xmppUser = new XMPPUser(this); }
| 1,113,162
|
void decline(final EMail invitedAs, final JabberId invitedBy) throws SmackException { final XMPPMethod decline = new XMPPMethod("contact:declineinvitation"); decline.setParameter(Xml.Contact.INVITED_AS, invitedAs); decline.setParameter(Xml.Contact.INVITED_BY, invitedBy); decline.setParameter(Xml.Contact.DECLINED_BY, xmppCore.getJabberId()); execute(decline); }
|
void decline(final EMail invitedAs, final JabberId invitedBy) throws SmackException { final XMPPMethod decline = new XMPPMethod("contact:declineinvitation"); decline.setParameter(Xml.Contact.INVITED_AS, invitedAs); decline.setParameter(Xml.Contact.INVITED_BY, invitedBy); decline.setParameter(Xml.Contact.DECLINED_BY, xmppCore.getJabberId()); execute(decline); }
| 1,113,163
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("archive:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("archive:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
| 1,113,165
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("archive:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); final XMPPMethod readDocumentVersions = new XMPPMethod("archive:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
| 1,113,166
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("archive:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("archive:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
| 1,113,167
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("backup:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("backup:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
| 1,113,168
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("backup:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); final XMPPMethod readDocumentVersions = new XMPPMethod("backup:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
| 1,113,169
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("backup:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); readDocumentVersions.setParameter("documentUniqueId", documentUniqueId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
|
List<DocumentVersion> readDocumentVersions(final JabberId userId, final UUID uniqueId, final Long versionId, final UUID documentUniqueId) { logger.logApiId(); logger.logVariable("userId", userId); logger.logVariable("uniqueId", uniqueId); logger.logVariable("versionId", versionId); logger.logVariable("documentUniqueId", documentUniqueId); final XMPPMethod readDocumentVersions = new XMPPMethod("backup:readdocumentversions"); readDocumentVersions.setParameter("userId", userId); readDocumentVersions.setParameter("uniqueId", uniqueId); readDocumentVersions.setParameter("versionId", versionId); return execute(readDocumentVersions, Boolean.TRUE).readResultDocumentVersions("documentVersions"); }
| 1,113,170
|
Contact read(final JabberId userId, final JabberId contactId) { logger.logApiId(); logger.logVariable("userId", userId); assertIsAuthenticatedUser(userId); final XMPPMethod read = new XMPPMethod("contact:read"); read.setParameter("userId", userId); read.setParameter("contactId", contactId); final XMPPMethodResponse response = execute(read, Boolean.TRUE); final Contact contact = new Contact(); contact.setId(response.readResultJabberId(Xml.Contact.JABBER_ID)); contact.setName(response.readResultString(Xml.Contact.NAME)); contact.setOrganization(response.readResultString(Xml.Contact.ORGANIZATION)); contact.setTitle(response.readResultString("title")); contact.addAllEmails(response.readResultEMails("emails")); return contact; }
|
Contact read(final JabberId userId, final JabberId contactId) { logger.logApiId(); logger.logVariable("userId", userId); assertIsAuthenticatedUser(userId); final XMPPMethod read = new XMPPMethod("contact:read"); read.setParameter("userId", userId); read.setParameter("contactId", contactId); final XMPPMethodResponse response = execute(read, Boolean.TRUE); final Contact contact = new Contact(); contact.setId(response.readResultJabberId(Xml.Contact.JABBER_ID)); contact.setName(response.readResultString(Xml.Contact.NAME)); contact.setOrganization(response.readResultString(Xml.Contact.ORGANIZATION)); contact.setTitle(response.readResultString("title")); contact.addAllEmails(response.readResultEMails("emails")); return contact; }
| 1,113,171
|
Contact read(final JabberId userId, final JabberId contactId) { logger.logApiId(); logger.logVariable("userId", userId); assertIsAuthenticatedUser(userId); final XMPPMethod read = new XMPPMethod("contact:read"); read.setParameter("userId", userId); read.setParameter("contactId", contactId); final XMPPMethodResponse response = execute(read, Boolean.TRUE); final Contact contact = new Contact(); contact.setId(response.readResultJabberId(Xml.Contact.JABBER_ID)); contact.setName(response.readResultString(Xml.Contact.NAME)); contact.setOrganization(response.readResultString(Xml.Contact.ORGANIZATION)); contact.setTitle(response.readResultString("title")); contact.addAllEmails(response.readResultEMails("emails")); return contact; }
|
Contact read(final JabberId userId, final JabberId contactId) { logger.logApiId(); logger.logVariable("userId", userId); assertIsAuthenticatedUser(userId); final XMPPMethod read = new XMPPMethod("contact:read"); read.setParameter("userId", userId); read.setParameter("contactId", contactId); final XMPPMethodResponse response = execute(read, Boolean.TRUE); final Contact contact = new Contact(); contact.setId(response.readResultJabberId(Xml.Contact.JABBER_ID)); contact.setName(response.readResultString(Xml.Contact.NAME)); contact.setOrganization(response.readResultString(Xml.Contact.ORGANIZATION)); contact.setTitle(response.readResultString("title")); contact.addAllEmails(response.readResultEMails("emails")); return contact; }
| 1,113,172
|
JabberId readKeyHolder(final JabberId userId, final UUID uniqueId) { final XMPPMethod method = new XMPPMethod("artifact:readkeyholder"); method.setParameter("userId", userId); method.setParameter("uniqueId", uniqueId); final XMPPMethodResponse result = execute(method); return result.readResultJabberId("keyHolder"); }
|
JabberId readKeyHolder(final JabberId userId, final UUID uniqueId) { final XMPPMethod method = new XMPPMethod("artifact:readkeyholder"); method.setParameter("userId", userId); method.setParameter("uniqueId", uniqueId); final XMPPMethodResponse result = execute(method); return result.readResultJabberId("keyHolder"); }
| 1,113,173
|
public QueueItem enqueue(final String message) throws ParityServerModelException { synchronized(implLock) { return impl.enqueue(message); } }
|
public QueueItem enqueue(final JID jid, final IQ iq) throws ParityServerModelException { synchronized(implLock) { return impl.enqueue(message); } }
| 1,113,174
|
public QueueItem enqueue(final String message) throws ParityServerModelException { synchronized(implLock) { return impl.enqueue(message); } }
|
public QueueItem enqueue(final String message) throws ParityServerModelException { synchronized(implLock) { return impl.enqueue(jid, iq); } }
| 1,113,175
|
void login(final String username, final String password) throws ParityException { logger.info("login(String,String)"); logger.debug(username); logger.debug(mask(password)); final String host = preferences.getServerHost(); final Integer port = preferences.getServerPort(); synchronized(xmppHelperLock) { try { final String usernameAtHost = new StringBuffer(username) .append("@").append(host).toString(); // check that the preferences username@host matches the username // supplied if(preferences.isSetUsername()) { Assert.assertTrue( ASSERT_USERNAME_EQUALS_PREFS, usernameAtHost.equals(preferences.getUsername())); } // login xmppHelper.login(host, port, username, password); // set the username@host in the preferences if(!preferences.isSetUsername()) { preferences.setUsername(usernameAtHost); } } catch(SmackException sx) { logger.error("login(String,String)", sx); throw ParityErrorTranslator.translate(sx); } catch(RuntimeException rx) { logger.error("login(String,String)", rx); throw ParityErrorTranslator.translate(rx); } } }
|
void login(final String username, final String password) throws ParityException { logger.info("login(String,String)"); logger.debug(username); logger.debug(mask(password)); final String host = preferences.getServerHost(); final Integer port = preferences.getServerPort(); synchronized(xmppHelperLock) { try { final String usernameAtHost = new StringBuffer(username) .append("@").append(host).toString(); // check that the preferences username@host matches the username // supplied if(preferences.isSetUsername()) { Assert.assertTrue( ASSERT_USERNAME_EQUALS_PREFS, usernameAtHost.equals(preferences.getUsername())); } // login xmppHelper.login(host, port, username, password); // set the username@host in the preferences if(!preferences.isSetUsername()) { preferences.setUsername(usernameAtHost); } } catch(SmackException sx) { logger.error("login(String,String)", sx); throw ParityErrorTranslator.translate(sx); } catch(RuntimeException rx) { logger.error("login(String,String)", rx); throw ParityErrorTranslator.translate(rx); } } }
| 1,113,176
|
void login(final String username, final String password) throws ParityException { logger.info("login(String,String)"); logger.debug(username); logger.debug(mask(password)); final String host = preferences.getServerHost(); final Integer port = preferences.getServerPort(); synchronized(xmppHelperLock) { try { final String usernameAtHost = new StringBuffer(username) .append("@").append(host).toString(); // check that the preferences username@host matches the username // supplied if(preferences.isSetUsername()) { Assert.assertTrue( ASSERT_USERNAME_EQUALS_PREFS, usernameAtHost.equals(preferences.getUsername())); } // login xmppHelper.login(host, port, username, password); // set the username@host in the preferences if(!preferences.isSetUsername()) { preferences.setUsername(usernameAtHost); } } catch(SmackException sx) { logger.error("login(String,String)", sx); throw ParityErrorTranslator.translate(sx); } catch(RuntimeException rx) { logger.error("login(String,String)", rx); throw ParityErrorTranslator.translate(rx); } } }
|
void login(final String username, final String password) throws ParityException { logger.info("login(String,String)"); logger.debug(username); logger.debug(mask(password)); final String host = preferences.getServerHost(); final Integer port = preferences.getServerPort(); synchronized(xmppHelperLock) { try { final String usernameAtHost = new StringBuffer(username) .append("@").append(host).toString(); // check that the preferences username@host matches the username // supplied if(preferences.isSetUsername()) { Assert.assertTrue( ASSERT_USERNAME_EQUALS_PREFS, username.equals(preferences.getUsername())); } // login xmppHelper.login(host, port, username, password); // set the username@host in the preferences if(!preferences.isSetUsername()) { preferences.setUsername(usernameAtHost); } } catch(SmackException sx) { logger.error("login(String,String)", sx); throw ParityErrorTranslator.translate(sx); } catch(RuntimeException rx) { logger.error("login(String,String)", rx); throw ParityErrorTranslator.translate(rx); } } }
| 1,113,177
|
void login(final String username, final String password) throws ParityException { logger.info("login(String,String)"); logger.debug(username); logger.debug(mask(password)); final String host = preferences.getServerHost(); final Integer port = preferences.getServerPort(); synchronized(xmppHelperLock) { try { final String usernameAtHost = new StringBuffer(username) .append("@").append(host).toString(); // check that the preferences username@host matches the username // supplied if(preferences.isSetUsername()) { Assert.assertTrue( ASSERT_USERNAME_EQUALS_PREFS, usernameAtHost.equals(preferences.getUsername())); } // login xmppHelper.login(host, port, username, password); // set the username@host in the preferences if(!preferences.isSetUsername()) { preferences.setUsername(usernameAtHost); } } catch(SmackException sx) { logger.error("login(String,String)", sx); throw ParityErrorTranslator.translate(sx); } catch(RuntimeException rx) { logger.error("login(String,String)", rx); throw ParityErrorTranslator.translate(rx); } } }
|
void login(final String username, final String password) throws ParityException { logger.info("login(String,String)"); logger.debug(username); logger.debug(mask(password)); final String host = preferences.getServerHost(); final Integer port = preferences.getServerPort(); synchronized(xmppHelperLock) { try { final String usernameAtHost = new StringBuffer(username) .append("@").append(host).toString(); // check that the preferences username@host matches the username // supplied if(preferences.isSetUsername()) { Assert.assertTrue( ASSERT_USERNAME_EQUALS_PREFS, usernameAtHost.equals(preferences.getUsername())); } // login xmppHelper.login(host, port, username, password); // set the username@host in the preferences if(!preferences.isSetUsername()) { preferences.setUsername(username); } } catch(SmackException sx) { logger.error("login(String,String)", sx); throw ParityErrorTranslator.translate(sx); } catch(RuntimeException rx) { logger.error("login(String,String)", rx); throw ParityErrorTranslator.translate(rx); } } }
| 1,113,178
|
private void fireNotification(final String notificationMessage) { final TrayNotification notification = new TrayNotification(); notification.setMessage(notificationMessage); impl.fireNotification(notification); }
|
private void fireNotification(final String notificationMessage) { final Notification notification = new Notification(); notification.setMessage(notificationMessage); impl.fireNotification(notification); }
| 1,113,180
|
void fireNotification(final TrayNotification notification) { synchronized(this) { queue.add(notification); notifyAll(); } }
|
void fireNotification(final TrayNotification notification) { synchronized(this) { queue.add(notification); notifyAll(); } }
| 1,113,182
|
SystemApplicationImpl(final SystemApplication sysApp) { super("[BROWSER2] [APP] [SYS] [THREAD]"); this.sysApp = sysApp; this.queue = new LinkedList<TrayNotification>(); }
|
SystemApplicationImpl(final SystemApplication sysApp) { super("[BROWSER2] [APP] [SYS] [THREAD]"); this.sysApp = sysApp; this.queue = new LinkedList<Notification>(); }
| 1,113,183
|
Document get(final UUID documentUniqueId) throws ParityException { logger.info("get(UUID)"); logger.debug(documentUniqueId); try { return documentIO.get(documentUniqueId); } catch(final RuntimeException rx) { logger.error("get(UUID)", rx); throw ParityErrorTranslator.translate(rx); } }
|
Document get(final UUID documentUniqueId) throws ParityException { logger.info("get(UUID)"); logger.debug(documentUniqueId); try { return documentIO.get(documentUniqueId); } catch(final RuntimeException rx) { logger.error("get(UUID)", rx); throw ParityErrorTranslator.translate(rx); } }
| 1,113,185
|
Collection<Document> list(final Comparator<Artifact> comparator) throws ParityException { logger.info("list(Comparator<Artifact>)"); logger.debug(comparator); try { final Collection<Document> documents = documentIO.list(); ArtifactSorter.sortDocuments(documents, comparator); return documents; } catch(RuntimeException rx) { logger.error("list(UUID,Comparator<Artifact>)", rx); throw ParityErrorTranslator.translate(rx); } }
|
Collection<Document> list(final Comparator<Artifact> comparator) throws ParityException { logger.info("list(Comparator<Artifact>)"); logger.debug(comparator); try { final Collection<Document> documents = documentIO.list(); ArtifactSorter.sortDocuments(documents, comparator); return documents; } catch(RuntimeException rx) { logger.error("list(UUID,Comparator<Artifact>)", rx); throw ParityErrorTranslator.translate(rx); } }
| 1,113,186
|
void receive(final XMPPDocument xmppDocument) throws ParityException { logger.info("receiveDocument(XMPPDocument)"); logger.debug(xmppDocument); try { Document document = get(xmppDocument.getUniqueId()); logger.debug(document); if(null == document) { document = receiveCreate(xmppDocument); } else { receiveUpdate(xmppDocument, document); } // audit the receiving auditor.recieve(document.getId(), xmppDocument.getVersionId(), xmppDocument.getCreatedBy(), xmppDocument.getUpdatedBy(), xmppDocument.getUpdatedOn()); } catch(IOException iox) { logger.error("receiveDocument(XMPPDocument)", iox); throw ParityErrorTranslator.translate(iox); } catch(RuntimeException rx) { logger.error("receiveDocument(XMPPDocument)", rx); throw ParityErrorTranslator.translate(rx); } }
|
void receive(final XMPPDocument xmppDocument) throws ParityException { logger.info("receiveDocument(XMPPDocument)"); logger.debug(xmppDocument); try { Document document = get(xmppDocument.getUniqueId()); logger.debug(document); if(null == document) { document = receiveCreate(xmppDocument); } else { receiveUpdate(xmppDocument, document); } // audit the receiving auditor.recieve(document.getId(), xmppDocument.getVersionId(), xmppDocument.getReceivedFrom(), xmppDocument.getUpdatedBy(), xmppDocument.getUpdatedOn()); } catch(IOException iox) { logger.error("receiveDocument(XMPPDocument)", iox); throw ParityErrorTranslator.translate(iox); } catch(RuntimeException rx) { logger.error("receiveDocument(XMPPDocument)", rx); throw ParityErrorTranslator.translate(rx); } }
| 1,113,187
|
protected static void assertNotNull(final String assertion, final Container container) { assertNotNull(assertion + " [CONTAINER IS NULL]", (Object) container); assertNotNull(assertion + " [CONTAINER'S CREATED BY IS NULL]", container.getCreatedBy()); assertNotNull(assertion + " [CONTAINER'S CREATED ON IS NULL]", container.getCreatedOn()); assertNotNull(assertion + " [CONTAINER'S FLAGS IS NULL]", container.getFlags()); assertNotNull(assertion + " [CONTAINER'S ID IS NULL]", container.getId()); assertNotNull(assertion + " [CONTAINER'S NAME IS NULL]", container.getName()); assertNotNull(assertion + " [CONTAINER'S REMOTE INFO IS NULL]", container.getRemoteInfo()); assertNotNull(assertion + " [CONTAINER'S UPDATED BY REMOTE INFO IS NULL]", container.getRemoteInfo().getUpdatedBy()); assertNotNull(assertion + " [CONTAINER'S UPDATED ON REMOTE INFO IS NULL]", container.getRemoteInfo().getUpdatedOn()); assertNotNull(assertion + " [CONTAINER'S STATE IS NULL]", container.getState()); assertNotNull(assertion + " [CONTAINER'S TYPE IS NULL]", container.getType()); assertNotNull(assertion + " [CONTAINER'S UNIQUE ID IS NULL]", container.getUniqueId()); assertNotNull(assertion + " [CONTAINER'S UPDATED BY IS NULL]", container.getUpdatedBy()); assertNotNull(assertion + " [CONTAINER'S UPDATED ON IS NULL]", container.getUpdatedOn()); }
|
protected static void assertNotNull(final String assertion, final Container container) { assertNotNull(assertion + " [CONTAINER IS NULL]", (Object) container); assertNotNull(assertion + " [CONTAINER'S CREATED BY IS NULL]", container.getCreatedBy()); assertNotNull(assertion + " [CONTAINER'S CREATED ON IS NULL]", container.getCreatedOn()); assertNotNull(assertion + " [CONTAINER'S FLAGS IS NULL]", container.getFlags()); assertNotNull(assertion + " [CONTAINER'S ID IS NULL]", container.getId()); assertNotNull(assertion + " [CONTAINER'S NAME IS NULL]", container.getName()); assertNotNull(assertion + " [CONTAINER'S REMOTE INFO IS NULL]", container.getRemoteInfo()); assertNotNull(assertion + " [CONTAINER'S UPDATED BY REMOTE INFO IS NULL]", container.getRemoteInfo().getUpdatedBy()); assertNotNull(assertion + " [CONTAINER'S UPDATED ON REMOTE INFO IS NULL]", container.getRemoteInfo().getUpdatedOn()); assertNotNull(assertion + " [CONTAINER'S STATE IS NULL]", container.getState()); assertNotNull(assertion + " [CONTAINER'S TYPE IS NULL]", container.getType()); assertNotNull(assertion + " [CONTAINER'S UNIQUE ID IS NULL]", container.getUniqueId()); assertNotNull(assertion + " [CONTAINER'S UPDATED BY IS NULL]", container.getUpdatedBy()); assertNotNull(assertion + " [CONTAINER'S UPDATED ON IS NULL]", container.getUpdatedOn()); }
| 1,113,188
|
public static Object invokeConstructor(String className, Object[] params) { try { Class converterClass= Class.forName(className); return ConstructorUtils.invokeConstructor(converterClass, params); } catch(Exception ex) { throw new JcrMappingException("Cannot create instance for class " + className, ex); } }
|
public static Object invokeConstructor(String className, Object[] params) { try { Class converterClass= forName(className); return ConstructorUtils.invokeConstructor(converterClass, params); } catch(Exception ex) { throw new JcrMappingException("Cannot create instance for class " + className, ex); } }
| 1,113,189
|
public static Object newInstance(String clazz) { try { return Class.forName(clazz).newInstance(); } catch(Exception ex) { throw new JcrMappingException("Cannot create instance for class " + clazz, ex); } }
|
public static Object newInstance(Class clazz) { try { return Class.forName(clazz).newInstance(); } catch(Exception ex) { throw new JcrMappingException("Cannot create instance for class " + clazz, ex); } }
| 1,113,190
|
public static Object newInstance(String clazz) { try { return Class.forName(clazz).newInstance(); } catch(Exception ex) { throw new JcrMappingException("Cannot create instance for class " + clazz, ex); } }
|
public static Object newInstance(String clazz) { try { return clazz.newInstance(); } catch(Exception ex) { throw new JcrMappingException("Cannot create instance for class " + clazz, ex); } }
| 1,113,191
|
public static ManageableCollection getManageableCollection(Object object) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Impossible to create the manageable collection", e); } throw new JcrMappingException("Unsupported collection type :" + object.getClass().getName()); }
|
public static ManageableCollection getManageableCollection(String manageableCollectionClassName) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Impossible to create the manageable collection", e); } throw new JcrMappingException("Unsupported collection type :" + object.getClass().getName()); }
| 1,113,192
|
public static ManageableCollection getManageableCollection(Object object) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Impossible to create the manageable collection", e); } throw new JcrMappingException("Unsupported collection type :" + object.getClass().getName()); }
|
public static ManageableCollection getManageableCollection(Object object) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Impossible to create the manageable collection", e); } throw new JcrMappingException("Unsupported collection type :" + object.getClass().getName()); }
| 1,113,193
|
public static ManageableCollection getManageableCollection(Object object) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Impossible to create the manageable collection", e); } throw new JcrMappingException("Unsupported collection type :" + object.getClass().getName()); }
|
public static ManageableCollection getManageableCollection(Object object) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Cannot create manageable collection : " + manageableCollectionClassName, e); } throw new JcrMappingException("Unsupported collection type :" + object.getClass().getName()); }
| 1,113,194
|
public static ManageableCollection getManageableCollection(Object object) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Impossible to create the manageable collection", e); } throw new JcrMappingException("Unsupported collection type :" + object.getClass().getName()); }
|
public static ManageableCollection getManageableCollection(Object object) { try { if (object == null) { return null; } if (object instanceof ManageableCollection) { return (ManageableCollection) object; } if (object.getClass().equals(ArrayList.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Vector.class)) { ManageableVector manageableVector = new ManageableVector(); manageableVector.addAll((Collection) object); return manageableVector; } if (object.getClass().equals(HashSet.class)) { return new ManageableSet((Set) object); } if (object.getClass().equals(Collection.class) || object.getClass().equals(List.class)) { ManageableArrayList manageableArrayList = new ManageableArrayList(); manageableArrayList.addAll((Collection) object); return manageableArrayList; } if (object.getClass().equals(Set.class)) { return new ManageableSet((Set) object); } } catch (Exception e) { throw new JcrMappingException("Impossible to create the manageable collection", e); } }
| 1,113,195
|
void logout() { logger.logApiId(); try { final XMPPSession xmppSession = workspace.getXMPPSession(); synchronized (xmppSession) { xmppSession.logout(); } } catch (final Throwable t) { throw translateError(t); } }
|
void logout() { logger.logApiId(); try { final XMPPSession xmppSession = workspace.getXMPPSession(); synchronized (xmppSession) { xmppSession.logout(); } } catch (final Throwable t) { throw translateError(t); } }
| 1,113,196
|
public List<DocumentView> readDocumentViews(final Long containerId, final Long versionId) { final Map<DocumentVersion, Delta> versions; final ContainerVersion previousVersion = containerModel.readPreviousVersion(containerId, versionId); if (null == previousVersion) { versions = containerModel.readDocumentVersionDeltas(containerId, versionId); } else { versions = containerModel.readDocumentVersionDeltas(containerId, versionId, previousVersion.getVersionId()); } final List<DocumentView> views = new ArrayList<DocumentView>(versions.size()); DocumentVersion firstVersion; DocumentView view; for (final Entry<DocumentVersion, Delta> entry : versions.entrySet()) { firstVersion = documentModel.readVersion( entry.getKey().getArtifactId(), Versioning.START); view = new DocumentView(); view.setDelta(entry.getValue()); view.setVersion(entry.getKey()); view.setFirstPublishedOn(firstVersion.getCreatedOn()); views.add(view); } return views; }
|
public List<DocumentView> readDocumentViews(final Long containerId, final Long versionId) { final Map<DocumentVersion, Delta> versions; final ContainerVersion previousVersion = containerModel.readPreviousVersion(containerId, versionId); if (null == previousVersion) { versions = containerModel.readDocumentVersionDeltas(containerId, versionId); } else { versions = containerModel.readDocumentVersionDeltas(containerId, versionId, previousVersion.getVersionId()); } final List<DocumentView> views = new ArrayList<DocumentView>(versions.size()); DocumentVersion firstVersion; DocumentView view; for (final Entry<DocumentVersion, Delta> entry : versions.entrySet()) { firstVersion = documentModel.readVersion( entry.getKey().getArtifactId(), Versioning.START); view = new DocumentView(); view.setDelta(entry.getValue()); view.setVersion(entry.getKey()); view.setFirstPublishedOn(firstVersion.getCreatedOn()); views.add(view); } return views; }
| 1,113,198
|
public void addListener(final XMPPExtensionListener l);
|
public void addListener(final XMPPArtifactListener l);
| 1,113,199
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.