public WorkspaceEditCapabilitiesDto(org.eclipse.lsp4j.WorkspaceEditCapabilities o) { if (o.getResourceOperations() == null) { setResourceOperations((java.util.List<java.lang.String>)null); } else { ArrayList<java.lang.String> resourceOperationsVal= new ArrayList<java.lang.String>(); for (java.lang.String resourceOperationsValX : o.getResourceOperations()) { java.lang.String resourceOperationsValY = (java.lang.String)makeDto(resourceOperationsValX);; resourceOperationsVal.add(resourceOperationsValY); } setResourceOperations((java.util.List<java.lang.String>)resourceOperationsVal); } if (o.getFailureHandling() == null) { setFailureHandling((java.lang.String)null); } else { java.lang.String failureHandlingVal = (java.lang.String)makeDto(o.getFailureHandling());; setFailureHandling((java.lang.String)failureHandlingVal); } if (o.getDocumentChanges() == null) { setDocumentChanges((java.lang.Boolean)null); } else { java.lang.Boolean documentChangesVal = (java.lang.Boolean)makeDto(o.getDocumentChanges());; setDocumentChanges((java.lang.Boolean)documentChangesVal); } if (o.getResourceChanges() == null) { setResourceChanges((java.lang.Boolean)null); } else { java.lang.Boolean resourceChangesVal = (java.lang.Boolean)makeDto(o.getResourceChanges());; setResourceChanges((java.lang.Boolean)resourceChangesVal); } }
@Override @Pure public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((this.applyEdit== null) ? 0 : this.applyEdit.hashCode()); result = prime * result + ((this.workspaceEdit== null) ? 0 : this.workspaceEdit.hashCode()); result = prime * result + ((this.didChangeConfiguration== null) ? 0 : this.didChangeConfiguration.hashCode()); result = prime * result + ((this.didChangeWatchedFiles== null) ? 0 : this.didChangeWatchedFiles.hashCode()); result = prime * result + ((this.symbol== null) ? 0 : this.symbol.hashCode()); result = prime * result + ((this.executeCommand== null) ? 0 : this.executeCommand.hashCode()); result = prime * result + ((this.workspaceFolders== null) ? 0 : this.workspaceFolders.hashCode()); return prime * result + ((this.configuration== null) ? 0 : this.configuration.hashCode()); } }
exeCap.setDynamicRegistration(true); workspaceCap.setExecuteCommand(exeCap); WorkspaceEditCapabilities workspaceEdit = new WorkspaceEditCapabilities(); workspaceEdit.setDocumentChanges(true); workspaceEdit.setResourceOperations(Arrays.asList(ResourceOperationKind.Create, ResourceOperationKind.Delete, ResourceOperationKind.Rename)); workspaceCap.setWorkspaceEdit(workspaceEdit); clientCap.setWorkspace(workspaceCap);
if (other.workspaceEdit != null) return false; } else if (!this.workspaceEdit.equals(other.workspaceEdit)) return false; if (this.didChangeConfiguration == null) {
public boolean isResourceOperationSupported() { //@formatter:off return capabilities.getWorkspace() != null && capabilities.getWorkspace().getWorkspaceEdit() != null && capabilities.getWorkspace().getWorkspaceEdit().getResourceOperations() != null && capabilities.getWorkspace().getWorkspaceEdit().getResourceOperations().contains(ResourceOperationKind.Create) && capabilities.getWorkspace().getWorkspaceEdit().getResourceOperations().contains(ResourceOperationKind.Rename) && capabilities.getWorkspace().getWorkspaceEdit().getResourceOperations().contains(ResourceOperationKind.Delete); //@formatter:on }
@Deprecated public boolean isWorkspaceEditResourceChangesSupported() { return capabilities.getWorkspace() != null && capabilities.getWorkspace().getWorkspaceEdit() != null && isTrue(capabilities.getWorkspace().getWorkspaceEdit().getResourceChanges()); }
workspace.setExecuteCommand(new ExecuteCommandCapabilities()); workspace.setSymbol(new SymbolCapabilities()); workspace.setWorkspaceEdit(new WorkspaceEditCapabilities()); clientCapabilities.setWorkspace(workspace);
if (other.workspaceEdit != null) return false; } else if (!this.workspaceEdit.equals(other.workspaceEdit)) return false; if (this.didChangeConfiguration == null) {
@Override @Pure public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((this.applyEdit== null) ? 0 : this.applyEdit.hashCode()); result = prime * result + ((this.workspaceEdit== null) ? 0 : this.workspaceEdit.hashCode()); result = prime * result + ((this.didChangeConfiguration== null) ? 0 : this.didChangeConfiguration.hashCode()); result = prime * result + ((this.didChangeWatchedFiles== null) ? 0 : this.didChangeWatchedFiles.hashCode()); result = prime * result + ((this.symbol== null) ? 0 : this.symbol.hashCode()); result = prime * result + ((this.executeCommand== null) ? 0 : this.executeCommand.hashCode()); result = prime * result + ((this.workspaceFolders== null) ? 0 : this.workspaceFolders.hashCode()); return prime * result + ((this.configuration== null) ? 0 : this.configuration.hashCode()); } }