1 /*******************************************************************************
2 * Copyright (c) 2012, 2015 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 * Francois Chouinard - Initial API and implementation
11 * Alexandre Montplaisir - Removed arrays from the API
12 * Patrick Tasse - Use ellipsis for getField and remove getSubField
13 *******************************************************************************/
15 package org
.eclipse
.tracecompass
.tmf
.core
.event
;
17 import java
.util
.Collection
;
19 import org
.eclipse
.jdt
.annotation
.NonNull
;
22 * The generic event payload in TMF. Each field can be either a terminal or
23 * further decomposed into subfields.
26 * @author Francois Chouinard
31 public interface ITmfEventField
{
33 // ------------------------------------------------------------------------
35 // ------------------------------------------------------------------------
38 * The root field id (the main container)
40 public static final @NonNull String ROOT_FIELD_ID
= ":root:"; //$NON-NLS-1$
42 // ------------------------------------------------------------------------
44 // ------------------------------------------------------------------------
47 * @return the field name
52 * @return the field value
57 * @return the value formatted as string
59 String
getFormattedValue();
62 * Return the subfield names. The iteration order is the same as
63 * {@link #getFields()}. The returned Collection is immutable.
65 * @return The subfield names (empty Collection if none)
67 Collection
<String
> getFieldNames();
70 * Return the subfields. The iteration order is the same as
71 * {@link #getFieldNames()}. The returned Collection is immutable.
73 * @return The subfields (empty Collection if none)
75 Collection
<?
extends ITmfEventField
> getFields();
78 * Return a subfield by its path relative to this field.
79 * If the path is empty, this field is returned.
80 * @param path The path to the subfield
81 * @return a specific subfield by path (null if inexistent)
83 ITmfEventField
getField(@NonNull String
... path
);
This page took 0.032545 seconds and 5 git commands to generate.