public final class LinearBooleanConstraint extends com.google.protobuf.GeneratedMessage implements LinearBooleanConstraintOrBuilder
A linear Boolean constraint which is a bounded sum of linear terms. Each term beeing a literal times an integer coefficient. If we assume that a literal takes the value 1 if it is true and 0 otherwise, the constraint is: lower_bound <= ... + coefficients[i] * literals[i] + ... <= upper_boundProtobuf type
operations_research.sat.LinearBooleanConstraint| Modifier and Type | Class and Description |
|---|---|
static class |
LinearBooleanConstraint.Builder
A linear Boolean constraint which is a bounded sum of linear terms.
|
com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.FieldAccessorTable, com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message,T>, com.google.protobuf.GeneratedMessage.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
COEFFICIENTS_FIELD_NUMBER |
static int |
LITERALS_FIELD_NUMBER |
static int |
LOWER_BOUND_FIELD_NUMBER |
static int |
NAME_FIELD_NUMBER |
static int |
UPPER_BOUND_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
long |
getCoefficients(int index)
repeated int64 coefficients = 2; |
int |
getCoefficientsCount()
repeated int64 coefficients = 2; |
java.util.List<java.lang.Long> |
getCoefficientsList()
repeated int64 coefficients = 2; |
static LinearBooleanConstraint |
getDefaultInstance() |
LinearBooleanConstraint |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
int |
getLiterals(int index)
Linear terms involved in this constraint.
|
int |
getLiteralsCount()
Linear terms involved in this constraint.
|
java.util.List<java.lang.Integer> |
getLiteralsList()
Linear terms involved in this constraint.
|
long |
getLowerBound()
Optional lower (resp.
|
java.lang.String |
getName()
The name of this constraint.
|
com.google.protobuf.ByteString |
getNameBytes()
The name of this constraint.
|
com.google.protobuf.Parser<LinearBooleanConstraint> |
getParserForType() |
int |
getSerializedSize() |
long |
getUpperBound()
optional int64 upper_bound = 4; |
int |
hashCode() |
boolean |
hasLowerBound()
Optional lower (resp.
|
boolean |
hasName()
The name of this constraint.
|
boolean |
hasUpperBound()
optional int64 upper_bound = 4; |
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static LinearBooleanConstraint.Builder |
newBuilder() |
static LinearBooleanConstraint.Builder |
newBuilder(LinearBooleanConstraint prototype) |
LinearBooleanConstraint.Builder |
newBuilderForType() |
protected LinearBooleanConstraint.Builder |
newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent) |
static LinearBooleanConstraint |
parseDelimitedFrom(java.io.InputStream input) |
static LinearBooleanConstraint |
parseDelimitedFrom(java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LinearBooleanConstraint |
parseFrom(byte[] data) |
static LinearBooleanConstraint |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LinearBooleanConstraint |
parseFrom(java.nio.ByteBuffer data) |
static LinearBooleanConstraint |
parseFrom(java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LinearBooleanConstraint |
parseFrom(com.google.protobuf.ByteString data) |
static LinearBooleanConstraint |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LinearBooleanConstraint |
parseFrom(com.google.protobuf.CodedInputStream input) |
static LinearBooleanConstraint |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LinearBooleanConstraint |
parseFrom(java.io.InputStream input) |
static LinearBooleanConstraint |
parseFrom(java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<LinearBooleanConstraint> |
parser() |
LinearBooleanConstraint.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashFields, toStringaddAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int LITERALS_FIELD_NUMBER
public static final int COEFFICIENTS_FIELD_NUMBER
public static final int LOWER_BOUND_FIELD_NUMBER
public static final int UPPER_BOUND_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessagepublic java.util.List<java.lang.Integer> getLiteralsList()
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;getLiteralsList in interface LinearBooleanConstraintOrBuilderpublic int getLiteralsCount()
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;getLiteralsCount in interface LinearBooleanConstraintOrBuilderpublic int getLiterals(int index)
Linear terms involved in this constraint. literals[i] is the signed representation of the i-th literal of the constraint and coefficients[i] its coefficients. The signed representation is as follow: for a 0-based variable index x, (x + 1) represents the variable x and -(x + 1) represents its negation. Note that the same variable shouldn't appear twice and that zero coefficients are not allowed.
repeated int32 literals = 1;getLiterals in interface LinearBooleanConstraintOrBuilderindex - The index of the element to return.public java.util.List<java.lang.Long> getCoefficientsList()
repeated int64 coefficients = 2;getCoefficientsList in interface LinearBooleanConstraintOrBuilderpublic int getCoefficientsCount()
repeated int64 coefficients = 2;getCoefficientsCount in interface LinearBooleanConstraintOrBuilderpublic long getCoefficients(int index)
repeated int64 coefficients = 2;getCoefficients in interface LinearBooleanConstraintOrBuilderindex - The index of the element to return.public boolean hasLowerBound()
Optional lower (resp. upper) bound of the constraint. If not present, it means that the constraint is not bounded in this direction. The bounds are INCLUSIVE.
optional int64 lower_bound = 3;hasLowerBound in interface LinearBooleanConstraintOrBuilderpublic long getLowerBound()
Optional lower (resp. upper) bound of the constraint. If not present, it means that the constraint is not bounded in this direction. The bounds are INCLUSIVE.
optional int64 lower_bound = 3;getLowerBound in interface LinearBooleanConstraintOrBuilderpublic boolean hasUpperBound()
optional int64 upper_bound = 4;hasUpperBound in interface LinearBooleanConstraintOrBuilderpublic long getUpperBound()
optional int64 upper_bound = 4;getUpperBound in interface LinearBooleanConstraintOrBuilderpublic boolean hasName()
The name of this constraint.
optional string name = 5 [default = ""];hasName in interface LinearBooleanConstraintOrBuilderpublic java.lang.String getName()
The name of this constraint.
optional string name = 5 [default = ""];getName in interface LinearBooleanConstraintOrBuilderpublic com.google.protobuf.ByteString getNameBytes()
The name of this constraint.
optional string name = 5 [default = ""];getNameBytes in interface LinearBooleanConstraintOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessagepublic void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessagejava.io.IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessagepublic boolean equals(java.lang.Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static LinearBooleanConstraint parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static LinearBooleanConstraint parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static LinearBooleanConstraint parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static LinearBooleanConstraint parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static LinearBooleanConstraint parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static LinearBooleanConstraint parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static LinearBooleanConstraint parseFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOExceptionpublic static LinearBooleanConstraint parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic static LinearBooleanConstraint parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOExceptionpublic static LinearBooleanConstraint parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic static LinearBooleanConstraint parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException
java.io.IOExceptionpublic static LinearBooleanConstraint parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic LinearBooleanConstraint.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static LinearBooleanConstraint.Builder newBuilder()
public static LinearBooleanConstraint.Builder newBuilder(LinearBooleanConstraint prototype)
public LinearBooleanConstraint.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected LinearBooleanConstraint.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
newBuilderForType in class com.google.protobuf.AbstractMessagepublic static LinearBooleanConstraint getDefaultInstance()
public static com.google.protobuf.Parser<LinearBooleanConstraint> parser()
public com.google.protobuf.Parser<LinearBooleanConstraint> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessagepublic LinearBooleanConstraint getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2024. All rights reserved.