-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public class
BasePact.Companion
-
Field Summary
Fields Modifier and Type Field Description private Consumer
consumer
private Provider
provider
private final Map<String, Object>
metadata
private final PactSource
source
private final List<Interaction>
interactions
-
Method Summary
Modifier and Type Method Description Consumer
getConsumer()
Returns the consumer of the service for the pact Unit
setConsumer(Consumer consumer)
Returns the consumer of the service for the pact Provider
getProvider()
Returns the provider of the service for the pact Unit
setProvider(Provider provider)
Returns the provider of the service for the pact Map<String, Object>
getMetadata()
Metadata associated with this Pact PactSource
getSource()
The source that this pact was loaded from abstract List<Interaction>
getInteractions()
Returns all the interactions of the pact Result<Integer, Throwable>
write(String pactDir, PactSpecVersion pactSpecVersion)
Write this Pact out to the provided file for the Pact specification version File
fileForPact(String pactDir)
Result<Boolean, String>
compatibleTo(Pact other)
If this pact is compatible with the other pact. Boolean
equals(Object other)
Integer
hashCode()
String
toString()
List<String>
validateForVersion(PactSpecVersion pactVersion)
Validates if this Pact can be used with the provided Pact specification version -
Methods inherited from class au.com.dius.pact.core.model.BasePact
asMessagePact, asRequestResponsePact, asV4Pact, isRequestResponsePact, mergeInteractions, sortInteractions, toMap
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
getConsumer
Consumer getConsumer()
Returns the consumer of the service for the pact
-
setConsumer
Unit setConsumer(Consumer consumer)
Returns the consumer of the service for the pact
-
getProvider
Provider getProvider()
Returns the provider of the service for the pact
-
setProvider
Unit setProvider(Provider provider)
Returns the provider of the service for the pact
-
getMetadata
Map<String, Object> getMetadata()
Metadata associated with this Pact
-
getSource
PactSource getSource()
The source that this pact was loaded from
-
getInteractions
abstract List<Interaction> getInteractions()
Returns all the interactions of the pact
-
write
Result<Integer, Throwable> write(String pactDir, PactSpecVersion pactSpecVersion)
Write this Pact out to the provided file for the Pact specification version
-
fileForPact
File fileForPact(String pactDir)
-
compatibleTo
Result<Boolean, String> compatibleTo(Pact other)
If this pact is compatible with the other pact. Pacts are compatible if they have the same provider and they are the same type
-
validateForVersion
List<String> validateForVersion(PactSpecVersion pactVersion)
Validates if this Pact can be used with the provided Pact specification version
-
-
-
-