Package org.brapi.schematools.analyse
Class BrAPISpecificationAnalyserFactory.Analyser
java.lang.Object
org.brapi.schematools.analyse.BrAPISpecificationAnalyserFactory.Analyser
- Enclosing class:
BrAPISpecificationAnalyserFactory
Analyser provides direct access to the analysis functions.
-
Method Summary
Modifier and TypeMethodDescriptionorg.brapi.schematools.core.response.Response<List<AnalysisReport>> Analyse all the endpoints in the specification.org.brapi.schematools.core.response.Response<List<AnalysisReport>> analyseEntities(List<String> entityNames) Analyse the endpoints for specific entities in the specification.org.brapi.schematools.core.response.Response<List<AnalysisReport>> analyseEntity(String entityName) Analyse the endpoints for specific entity in the specification.org.brapi.schematools.core.response.Response<List<AnalysisReport>> Analyse the special endpoints that do not fit the regular entity endpoints.Gets a list of deprecated endpoints that will be skipped.Gets a list of endpoints that are to be tested.Get the list of entities available on the serverorg.brapi.schematools.core.response.Response<List<APIRequest>> Get any errors found in the specificationGets a list of endpoints that will not be tested under due to the current option settings.Gets a list of endpoints that are not tested under any situation.org.brapi.schematools.core.response.Response<BrAPISpecificationAnalyserFactory.Analyser> validate()Validates the options against the specification.
-
Method Details
-
getEntityNames
Get the list of entities available on the server- Returns:
- list of entities available on the server
-
getEndpoints
Gets a list of endpoints that are to be tested.- Returns:
- a list of endpoints that are to be tested.
-
getUnmatchedEndpoints
Gets a list of endpoints that are not tested under any situation.- Returns:
- a list of endpoints that are not tested under any situation
-
getSkippedEndpoints
Gets a list of endpoints that will not be tested under due to the current option settings.- Returns:
- a list of endpoints that will not be tested under due to the current option settings
-
getDeprecatedEndpoints
Gets a list of deprecated endpoints that will be skipped.- Returns:
- a list of deprecated endpoints that will be skipped.
-
analyseAll
Analyse all the endpoints in the specification. Does not callAnalysisOptions.validate()oranalyseSpecial().- Returns:
- A response containing a list of AnalysisReports or failure explaining why it failed.
-
analyseEntities
public org.brapi.schematools.core.response.Response<List<AnalysisReport>> analyseEntities(List<String> entityNames) Analyse the endpoints for specific entities in the specification. Does not callAnalysisOptions.validate()oranalyseSpecial().- Parameters:
entityNames- a list of entities to be analysed- Returns:
- A response containing a list of AnalysisReports or failure explaining why it failed.
-
analyseEntity
public org.brapi.schematools.core.response.Response<List<AnalysisReport>> analyseEntity(String entityName) Analyse the endpoints for specific entity in the specification. Does not callanalyseSpecial().- Parameters:
entityName- an entity to be analysed- Returns:
- A response containing a list of AnalysisReports or failure explaining why it failed.
-
analyseSpecial
Analyse the special endpoints that do not fit the regular entity endpoints. For example the /commoncropnames endpoint.- Returns:
- A response containing a list of AnalysisReports or failure explaining why it failed.
-
validate
public org.brapi.schematools.core.response.Response<BrAPISpecificationAnalyserFactory.Analyser> validate()Validates the options against the specification.- Returns:
- A response containing this Analyser or failure explaining why it failed.
-
getErrors
Get any errors found in the specification- Returns:
- any errors found in the specification
-