1 /**********************************************************************
2 * Copyright (c) 2012 Ericsson
4 * All rights reserved. This program and the accompanying materials are
5 * made available under the terms of the Eclipse Public License v1.0 which
6 * accompanies this distribution, and is available at
7 * http://www.eclipse.org/legal/epl-v10.html
10 * Bernd Hufmann - Initial API and implementation
11 **********************************************************************/
12 package org
.eclipse
.linuxtools
.internal
.lttng
.ui
.views
.control
.service
;
14 import java
.util
.Arrays
;
17 * <b><u>CommandResult</u></b>
19 * Class containing command result of remote command execution.
22 public class CommandResult
implements ICommandResult
{
24 // ------------------------------------------------------------------------
26 // ------------------------------------------------------------------------
28 * The result of the command. 0 if successful else > 0
33 * The output as String array.
35 private String
[] fOutput
= new String
[0];
37 // ------------------------------------------------------------------------
39 // ------------------------------------------------------------------------
40 public CommandResult(int result
, String
[] output
) {
43 fOutput
= Arrays
.copyOf(output
, output
.length
);
47 // ------------------------------------------------------------------------
49 // ------------------------------------------------------------------------
52 * @see org.eclipse.linuxtools.internal.lttng.ui.views.control.service.ICommandResult#getResult()
55 public int getResult() {
61 * @see org.eclipse.linuxtools.internal.lttng.ui.views.control.service.ICommandResult#setResult(int)
64 public void setResult(int result
) {
70 * @see org.eclipse.linuxtools.internal.lttng.ui.views.control.service.ICommandResult#getOutput()
73 public String
[] getOutput() {
74 return Arrays
.copyOf(fOutput
, fOutput
.length
);
79 * @see org.eclipse.linuxtools.internal.lttng.ui.views.control.service.ICommandResult#setOutput(java.lang.String[])
82 public void setOutput(String
[] output
) {
83 fOutput
= new String
[0];
85 fOutput
= Arrays
.copyOf(output
, output
.length
);
This page took 0.044346 seconds and 5 git commands to generate.