Class Source
- java.lang.Object
-
- com.azure.resourcemanager.monitor.models.Source
-
public final class Source extends Object
Specifies the log search query.
-
-
Constructor Summary
Constructors Constructor Description Source()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<String>authorizedResources()Get the authorizedResources property: List of Resource referred into query.StringdataSourceId()Get the dataSourceId property: The resource uri over which log search query is to be run.Stringquery()Get the query property: Log search query.QueryTypequeryType()Get the queryType property: Set value to 'ResultCount' .voidvalidate()Validates the instance.SourcewithAuthorizedResources(List<String> authorizedResources)Set the authorizedResources property: List of Resource referred into query.SourcewithDataSourceId(String dataSourceId)Set the dataSourceId property: The resource uri over which log search query is to be run.SourcewithQuery(String query)Set the query property: Log search query.SourcewithQueryType(QueryType queryType)Set the queryType property: Set value to 'ResultCount' .
-
-
-
Method Detail
-
query
public String query()
Get the query property: Log search query. Required for action type - AlertingAction.- Returns:
- the query value.
-
withQuery
public Source withQuery(String query)
Set the query property: Log search query. Required for action type - AlertingAction.- Parameters:
query- the query value to set.- Returns:
- the Source object itself.
-
authorizedResources
public List<String> authorizedResources()
Get the authorizedResources property: List of Resource referred into query.- Returns:
- the authorizedResources value.
-
withAuthorizedResources
public Source withAuthorizedResources(List<String> authorizedResources)
Set the authorizedResources property: List of Resource referred into query.- Parameters:
authorizedResources- the authorizedResources value to set.- Returns:
- the Source object itself.
-
dataSourceId
public String dataSourceId()
Get the dataSourceId property: The resource uri over which log search query is to be run.- Returns:
- the dataSourceId value.
-
withDataSourceId
public Source withDataSourceId(String dataSourceId)
Set the dataSourceId property: The resource uri over which log search query is to be run.- Parameters:
dataSourceId- the dataSourceId value to set.- Returns:
- the Source object itself.
-
queryType
public QueryType queryType()
Get the queryType property: Set value to 'ResultCount' .- Returns:
- the queryType value.
-
withQueryType
public Source withQueryType(QueryType queryType)
Set the queryType property: Set value to 'ResultCount' .- Parameters:
queryType- the queryType value to set.- Returns:
- the Source object itself.
-
validate
public void validate()
Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
-