1 /**********************************************************************
2 * Copyright (c) 2012, 2013 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
.lttng2
.core
.control
.model
.impl
;
14 import org
.eclipse
.linuxtools
.internal
.lttng2
.core
.control
.model
.IFieldInfo
;
18 * Implementation of the basic trace event interface (IEventInfo) to store event
22 * @author Bernd Hufmann
24 public class FieldInfo
extends TraceInfo
implements IFieldInfo
{
26 // ------------------------------------------------------------------------
28 // ------------------------------------------------------------------------
30 * The trace event type.
32 private String fFieldType
;
34 // ------------------------------------------------------------------------
36 // ------------------------------------------------------------------------
39 * @param name - name of base event
41 public FieldInfo(String name
) {
47 * @param other - the instance to copy
49 public FieldInfo(FieldInfo other
) {
51 fFieldType
= other
.fFieldType
;
54 // ------------------------------------------------------------------------
56 // ------------------------------------------------------------------------
59 public String
getFieldType() {
64 public void setFieldType(String fieldType
) {
65 fFieldType
= fieldType
;
69 public int hashCode() {
71 int result
= super.hashCode();
72 result
= prime
* result
73 + ((fFieldType
== null) ?
0 : fFieldType
.hashCode());
78 public boolean equals(Object obj
) {
82 if (!super.equals(obj
)) {
85 if (getClass() != obj
.getClass()) {
88 FieldInfo other
= (FieldInfo
) obj
;
89 if (fFieldType
== null) {
90 if (other
.fFieldType
!= null) {
93 } else if (!fFieldType
.equals(other
.fFieldType
)) {
99 @SuppressWarnings("nls")
101 public String
toString() {
102 StringBuffer output
= new StringBuffer();
103 output
.append("[FieldInfo(");
104 output
.append(super.toString());
105 output
.append(",type=");
106 output
.append(fFieldType
);
107 return output
.toString();
This page took 0.034585 seconds and 6 git commands to generate.