Class JClass
java.lang.Object
edu.university.ecs.lab.common.models.ir.ProjectFile
edu.university.ecs.lab.common.models.ir.JClass
- All Implemented Interfaces:
JsonSerializable
Represents a class in Java. It holds all information regarding that class including all method
declarations, method calls, fields, etc.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Set<Annotation>Set of class level annotationsprivate ClassRoleRole of the class in the microservice system.Set of class fieldsClass implementationsprivate List<MethodCall>List of method invocations made from within this classSet of methods in the classprivate StringFields inherited from class edu.university.ecs.lab.common.models.ir.ProjectFile
fileType, name, path -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThis method returns all endpoints found in the methods of this class, grouped under the same list as an Endpoint is an extension of a Method seeEndpointThis method returns all restCalls found in the methodCalls of this class, grouped under the same list as an RestCall is an extension of a MethodCall seeRestCallcom.google.gson.JsonObjectvoidupdateMicroserviceName(String name) If we are adding a class or a class is being adopted/orphanized lets update ms name
-
Field Details
-
packageName
-
implementedTypes
Class implementations -
classRole
Role of the class in the microservice system. SeeClassRole -
methods
Set of methods in the class -
fields
Set of class fields -
annotations
Set of class level annotations -
methodCalls
List of method invocations made from within this class
-
-
Constructor Details
-
JClass
-
JClass
-
-
Method Details
-
toJsonObject
public com.google.gson.JsonObject toJsonObject()- Specified by:
toJsonObjectin interfaceJsonSerializable- Overrides:
toJsonObjectin classProjectFile- Returns:
- a JsonObject representing this
-
getEndpoints
This method returns all endpoints found in the methods of this class, grouped under the same list as an Endpoint is an extension of a Method seeEndpoint- Returns:
- set of all endpoints
-
getRestCalls
This method returns all restCalls found in the methodCalls of this class, grouped under the same list as an RestCall is an extension of a MethodCall seeRestCall- Returns:
- set of all restCalls
-
updateMicroserviceName
If we are adding a class or a class is being adopted/orphanized lets update ms name- Parameters:
name-
-