Record Class CaptureService.McpLocatorCandidate
java.lang.Object
java.lang.Record
com.shaft.mcp.CaptureService.McpLocatorCandidate
- Record Components:
strategy- locator strategy name (ROLE, ACCESSIBLE_NAME, LABEL, TEST_ID, ID, NAME, CSS, XPATH)expression- raw locator expressionuniquenessCount- number of matching elements observed on the live pagevisible- whether the target was visiblestable- whether the evidence appeared stable
- Enclosing class:
CaptureService
-
Constructor Summary
ConstructorsConstructorDescriptionMcpLocatorCandidate(String strategy, String expression, int uniquenessCount, boolean visible, boolean stable) Creates an instance of aMcpLocatorCandidaterecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the value of theexpressionrecord component.final inthashCode()Returns a hash code value for this object.booleanstable()Returns the value of thestablerecord component.strategy()Returns the value of thestrategyrecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of theuniquenessCountrecord component.booleanvisible()Returns the value of thevisiblerecord component.
-
Constructor Details
-
McpLocatorCandidate
public McpLocatorCandidate(String strategy, String expression, int uniquenessCount, boolean visible, boolean stable) Creates an instance of aMcpLocatorCandidaterecord class.- Parameters:
strategy- the value for thestrategyrecord componentexpression- the value for theexpressionrecord componentuniquenessCount- the value for theuniquenessCountrecord componentvisible- the value for thevisiblerecord componentstable- the value for thestablerecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
strategy
-
expression
Returns the value of theexpressionrecord component.- Returns:
- the value of the
expressionrecord component
-
uniquenessCount
public int uniquenessCount()Returns the value of theuniquenessCountrecord component.- Returns:
- the value of the
uniquenessCountrecord component
-
visible
-
stable
-