package com.perforce.p4java_ext; import com.perforce.p4java.server.IOptionsServer; class DefaultP4Connection implements P4Connection { private IOptionsServer optionsServer; private String login; public DefaultP4Connection(IOptionsServer optionsServer) { this.optionsServer = optionsServer; } public DefaultP4Connection(P4Connection conn) { this.optionsServer = conn.getOptionsServer(); this.login = conn.getLogin(); } @Override public IOptionsServer getOptionsServer() { return optionsServer; } @Override public String getLogin() { return login; } @Override public void setLogin(String login) { this.login = login; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; DefaultP4Connection that = (DefaultP4Connection) o; if (login != null ? !login.equals(that.login) : that.login != null) return false; if (optionsServer != null ? !optionsServer.equals(that.optionsServer) : that.optionsServer != null) return false; return true; } @Override public int hashCode() { int result = optionsServer != null ? optionsServer.hashCode() : 0; result = 31 * result + (login != null ? login.hashCode() : 0); return result; } @Override public String toString() { return "DefaultP4Connection{" + "login='" + login + '\'' + '}'; } }
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#2 | 9086 | tjuricek |
0.1.0 Initial release of p4java_ext Mostly just contains enough of the P4 API to build the test data initializer. About 4 commands have minimal testing, so it works. Kind of. |
||
#1 | 9085 | tjuricek | First import of the project, before package refactoring. |