public class DataModelObject extends Object
Modifier | Constructor and Description |
---|---|
protected |
DataModelObject(DataModel model) |
Modifier and Type | Method and Description |
---|---|
boolean |
containsField(String fieldName)
Checks whether there is a field with the given name in this
data model object.
|
Job |
createLocalAccelerationJob()
Local acceleration is tsidx acceleration of a data model object that is handled
manually by a user.
|
Job |
createLocalAccelerationJob(String earliestTime)
Local acceleration is tsidx acceleration of a data model object that is handled
manually by a user.
|
PivotSpecification |
createPivotSpecification()
Create a PivotSpecification on this data model object.
|
Collection<DataModelField> |
getAutoExtractedFields()
Get a collection of objects specifying all the fields that were automatically extracted
from events (as opposed to generated by calculations in a data model).
|
DataModelCalculation |
getCalculation(String calculationId)
Fetch a calculation by its unique ID.
|
Map<String,DataModelCalculation> |
getCalculations()
Return the calculations done by this data model object to produce fields.
|
Collection<DataModelConstraint> |
getConstraints() |
DataModel |
getDataModel()
Fetch the data model on which this object is defined.
|
String |
getDisplayName() |
DataModelField |
getField(String fieldName)
Fetch a single field of a given name from this data model object.
|
Collection<DataModelField> |
getFields()
Return all the fields, whether input or created by calculations.
|
String[] |
getLineage()
Data model objects can inherit from other data model objects
in the same data model (or from a couple of global base objects
such as BaseEvent and BaseTransaction).
|
String |
getName() |
DataModelObject |
getParent() |
String |
getParentName()
Returns the name of the parent of this object.
|
String |
getQuery() |
Job |
runQuery()
Start a job that fetches all the events of this data model object.
|
Job |
runQuery(JobArgs args)
Start a job that fetches all the events of this data model object.
|
Job |
runQuery(String querySuffix)
Start a job that applies querySuffix to all the events in this data model object.
|
Job |
runQuery(String querySuffix,
JobArgs args)
Start a job that applies querySuffix to all the events in this data model object.
|
protected DataModelObject(DataModel model)
public boolean containsField(String fieldName)
fieldName
- name of the field to check for.public Job createLocalAccelerationJob()
public Job createLocalAccelerationJob(String earliestTime)
earliestTime
- A time modifier (e.g., "-2w") setting the earliest time to index.public Map<String,DataModelCalculation> getCalculations()
public DataModelCalculation getCalculation(String calculationId)
calculationId
- a splunkd assigned unique ID for this calculation.public Collection<DataModelConstraint> getConstraints()
public DataModel getDataModel()
public String getDisplayName()
public DataModelField getField(String fieldName)
fieldName
- Name of the field to fetch.public Collection<DataModelField> getAutoExtractedFields()
public Collection<DataModelField> getFields()
public String getQuery()
public String getName()
public String[] getLineage()
public String getParentName()
public DataModelObject getParent()
public PivotSpecification createPivotSpecification()
public Job runQuery()
public Job runQuery(JobArgs args)
args
- arguments specifying behavior of the job.public Job runQuery(String querySuffix)
querySuffix
- a search query, starting with a '|' that will be appended to the command to fetch
the contents of this data model object (e.g., "| head 3").public Job runQuery(String querySuffix, JobArgs args)
querySuffix
- a search query, starting with a '|' that will be appended to the command to fetch
the contents of this data model object (e.g., "| head 3").args
- arguments to control the job.Copyright © 2022 Splunk, Inc.. All rights reserved.