Package org.optaplanner.core.impl.score.stream.bi

## Interface InnerBiConstraintStream<A,​B>

- All Superinterfaces:
    `BiConstraintStream<A,​B>`, `ConstraintStream`
  All Known Implementing Classes:
    `BavetAbstractBiConstraintStream`, `BavetFilterBiConstraintStream`, `BavetGroupBiConstraintStream`, `BavetGroupBridgeBiConstraintStream`, `BavetJoinBiConstraintStream`, `BavetJoinBridgeBiConstraintStream`, `BavetScoringBiConstraintStream`, `DroolsAbstractBiConstraintStream`, `DroolsExistsBiConstraintStream`, `DroolsFilterBiConstraintStream`, `DroolsFlatteningBiConstraintStream`, `DroolsGroupingBiConstraintStream`, `DroolsJoinBiConstraintStream`

      public interface InnerBiConstraintStream<A,​B>
      extends BiConstraintStream<A,​B>

- - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `default BiConstraintStream<A,​B>` | `distinct()` | Transforms the stream in such a way that all the tuples going through it are distinct.
    `boolean` | `guaranteesDistinct()` | This method will return true if the constraint stream is guaranteed to only produce distinct tuples.
    `default Constraint` | `impact​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToIntBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.impact(String, Score, ToIntBiFunction)`.
    `default Constraint` | `impactBigDecimal​(String constraintPackage, String constraintName, Score<?> constraintWeight, BiFunction<A,​B,​BigDecimal> matchWeigher)` | As defined by `BiConstraintStream.impactBigDecimal(String, Score, BiFunction)`.
    `default Constraint` | `impactConfigurable​(String constraintPackage, String constraintName, ToIntBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.impactConfigurable(String, ToIntBiFunction)`.
    `default Constraint` | `impactConfigurableBigDecimal​(String constraintPackage, String constraintName, BiFunction<A,​B,​BigDecimal> matchWeigher)` | As defined by `BiConstraintStream.impactConfigurableBigDecimal(String, BiFunction)`.
    `default Constraint` | `impactConfigurableLong​(String constraintPackage, String constraintName, ToLongBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.impactConfigurableLong(String, ToLongBiFunction)`.
    `default Constraint` | `impactLong​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToLongBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.impactLong(String, Score, ToLongBiFunction)`.
    `Constraint` | `impactScore​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToIntBiFunction<A,​B> matchWeigher, ScoreImpactType impactType)` |
    `Constraint` | `impactScoreBigDecimal​(String constraintPackage, String constraintName, Score<?> constraintWeight, BiFunction<A,​B,​BigDecimal> matchWeigher, ScoreImpactType impactType)` |
    `Constraint` | `impactScoreConfigurable​(String constraintPackage, String constraintName, ToIntBiFunction<A,​B> matchWeigher, ScoreImpactType impactType)` |
    `Constraint` | `impactScoreConfigurableBigDecimal​(String constraintPackage, String constraintName, BiFunction<A,​B,​BigDecimal> matchWeigher, ScoreImpactType impactType)` |
    `Constraint` | `impactScoreConfigurableLong​(String constraintPackage, String constraintName, ToLongBiFunction<A,​B> matchWeigher, ScoreImpactType impactType)` |
    `Constraint` | `impactScoreLong​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToLongBiFunction<A,​B> matchWeigher, ScoreImpactType impactType)` |
    `default Constraint` | `penalize​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToIntBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.penalize(String, Score, ToIntBiFunction)`.
    `default Constraint` | `penalizeBigDecimal​(String constraintPackage, String constraintName, Score<?> constraintWeight, BiFunction<A,​B,​BigDecimal> matchWeigher)` | As defined by `BiConstraintStream.penalizeBigDecimal(String, Score, BiFunction)`.
    `default Constraint` | `penalizeConfigurable​(String constraintPackage, String constraintName, ToIntBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.penalizeConfigurable(String, ToIntBiFunction)`.
    `default Constraint` | `penalizeConfigurableBigDecimal​(String constraintPackage, String constraintName, BiFunction<A,​B,​BigDecimal> matchWeigher)` | As defined by `BiConstraintStream.penalizeConfigurableBigDecimal(String, BiFunction)`.
    `default Constraint` | `penalizeConfigurableLong​(String constraintPackage, String constraintName, ToLongBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.penalizeConfigurableLong(String, ToLongBiFunction)`.
    `default Constraint` | `penalizeLong​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToLongBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.penalizeLong(String, Score, ToLongBiFunction)`.
    `default Constraint` | `reward​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToIntBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.reward(String, Score, ToIntBiFunction)`.
    `default Constraint` | `rewardBigDecimal​(String constraintPackage, String constraintName, Score<?> constraintWeight, BiFunction<A,​B,​BigDecimal> matchWeigher)` | As defined by `BiConstraintStream.rewardBigDecimal(String, Score, BiFunction)`.
    `default Constraint` | `rewardConfigurable​(String constraintPackage, String constraintName, ToIntBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.rewardConfigurable(String, ToIntBiFunction)`.
    `default Constraint` | `rewardConfigurableBigDecimal​(String constraintPackage, String constraintName, BiFunction<A,​B,​BigDecimal> matchWeigher)` | As defined by `BiConstraintStream.rewardConfigurableBigDecimal(String, BiFunction)`.
    `default Constraint` | `rewardConfigurableLong​(String constraintPackage, String constraintName, ToLongBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.rewardConfigurableLong(String, ToLongBiFunction)`.
    `default Constraint` | `rewardLong​(String constraintPackage, String constraintName, Score<?> constraintWeight, ToLongBiFunction<A,​B> matchWeigher)` | As defined by `BiConstraintStream.rewardLong(String, Score, ToLongBiFunction)`.

    - ### Methods inherited from interface org.optaplanner.core.api.score.stream.bi.BiConstraintStream

      `filter, flattenLast, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, groupBy, ifExists, ifExists, ifExists, ifExists, ifExists, ifNotExists, ifNotExists, ifNotExists, ifNotExists, ifNotExists, impact, impactBigDecimal, impactConfigurable, impactConfigurableBigDecimal, impactConfigurableLong, impactLong, join, join, join, join, join, join, join, join, join, join, join, join, map, penalize, penalizeBigDecimal, penalizeConfigurable, penalizeConfigurableBigDecimal, penalizeConfigurableLong, penalizeLong, reward, rewardBigDecimal, rewardConfigurable, rewardConfigurableBigDecimal, rewardConfigurableLong, rewardLong`

    - ### Methods inherited from interface org.optaplanner.core.api.score.stream.ConstraintStream

      `getConstraintFactory, impact, impact, penalize, penalize, penalizeConfigurable, penalizeConfigurable, reward, reward, rewardConfigurable, rewardConfigurable`

- - ### Method Detail

    - #### guaranteesDistinct

          boolean guaranteesDistinct()

      This method will return true if the constraint stream is guaranteed to only produce distinct tuples. See `distinct()` for details.
      Returns:
        true if the guarantee of distinct tuples is provided

    - #### distinct

          default BiConstraintStream<A,​B> distinct()

      Description copied from interface: `BiConstraintStream`
      Transforms the stream in such a way that all the tuples going through it are distinct. (No two result tuples are `equal`.)

      By default, tuples going through a constraint stream are distinct. However, operations such as `BiConstraintStream.map(BiFunction)` may create a stream which breaks that promise. By calling this method on such a stream, duplicate copies of the same tuple are omitted at a performance cost.

      Specified by:
        `distinct` in interface `BiConstraintStream<A,​B>`
      Returns:
        never null

    - #### penalize

          default Constraint penalize​(String constraintPackage,
                                      String constraintName,
                                      Score<?> constraintWeight,
                                      ToIntBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.penalize(String, Score, ToIntBiFunction)`.
      Specified by:
        `penalize` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### penalizeLong

          default Constraint penalizeLong​(String constraintPackage,
                                          String constraintName,
                                          Score<?> constraintWeight,
                                          ToLongBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.penalizeLong(String, Score, ToLongBiFunction)`.
      Specified by:
        `penalizeLong` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### penalizeBigDecimal

          default Constraint penalizeBigDecimal​(String constraintPackage,
                                                String constraintName,
                                                Score<?> constraintWeight,
                                                BiFunction<A,​B,​BigDecimal> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.penalizeBigDecimal(String, Score, BiFunction)`.
      Specified by:
        `penalizeBigDecimal` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### penalizeConfigurable

          default Constraint penalizeConfigurable​(String constraintPackage,
                                                  String constraintName,
                                                  ToIntBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.penalizeConfigurable(String, ToIntBiFunction)`.
      Specified by:
        `penalizeConfigurable` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### penalizeConfigurableLong

          default Constraint penalizeConfigurableLong​(String constraintPackage,
                                                      String constraintName,
                                                      ToLongBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.penalizeConfigurableLong(String, ToLongBiFunction)`.
      Specified by:
        `penalizeConfigurableLong` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### penalizeConfigurableBigDecimal

          default Constraint penalizeConfigurableBigDecimal​(String constraintPackage,
                                                            String constraintName,
                                                            BiFunction<A,​B,​BigDecimal> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.penalizeConfigurableBigDecimal(String, BiFunction)`.
      Specified by:
        `penalizeConfigurableBigDecimal` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### reward

          default Constraint reward​(String constraintPackage,
                                    String constraintName,
                                    Score<?> constraintWeight,
                                    ToIntBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.reward(String, Score, ToIntBiFunction)`.
      Specified by:
        `reward` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### rewardLong

          default Constraint rewardLong​(String constraintPackage,
                                        String constraintName,
                                        Score<?> constraintWeight,
                                        ToLongBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.rewardLong(String, Score, ToLongBiFunction)`.
      Specified by:
        `rewardLong` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### rewardBigDecimal

          default Constraint rewardBigDecimal​(String constraintPackage,
                                              String constraintName,
                                              Score<?> constraintWeight,
                                              BiFunction<A,​B,​BigDecimal> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.rewardBigDecimal(String, Score, BiFunction)`.
      Specified by:
        `rewardBigDecimal` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### rewardConfigurable

          default Constraint rewardConfigurable​(String constraintPackage,
                                                String constraintName,
                                                ToIntBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.rewardConfigurable(String, ToIntBiFunction)`.
      Specified by:
        `rewardConfigurable` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### rewardConfigurableLong

          default Constraint rewardConfigurableLong​(String constraintPackage,
                                                    String constraintName,
                                                    ToLongBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.rewardConfigurableLong(String, ToLongBiFunction)`.
      Specified by:
        `rewardConfigurableLong` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### rewardConfigurableBigDecimal

          default Constraint rewardConfigurableBigDecimal​(String constraintPackage,
                                                          String constraintName,
                                                          BiFunction<A,​B,​BigDecimal> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.rewardConfigurableBigDecimal(String, BiFunction)`.
      Specified by:
        `rewardConfigurableBigDecimal` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### impact

          default Constraint impact​(String constraintPackage,
                                    String constraintName,
                                    Score<?> constraintWeight,
                                    ToIntBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.impact(String, Score, ToIntBiFunction)`.
      Specified by:
        `impact` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### impactLong

          default Constraint impactLong​(String constraintPackage,
                                        String constraintName,
                                        Score<?> constraintWeight,
                                        ToLongBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.impactLong(String, Score, ToLongBiFunction)`.
      Specified by:
        `impactLong` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### impactBigDecimal

          default Constraint impactBigDecimal​(String constraintPackage,
                                              String constraintName,
                                              Score<?> constraintWeight,
                                              BiFunction<A,​B,​BigDecimal> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.impactBigDecimal(String, Score, BiFunction)`.
      Specified by:
        `impactBigDecimal` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `constraintWeight` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### impactConfigurable

          default Constraint impactConfigurable​(String constraintPackage,
                                                String constraintName,
                                                ToIntBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.impactConfigurable(String, ToIntBiFunction)`.
      Specified by:
        `impactConfigurable` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### impactConfigurableLong

          default Constraint impactConfigurableLong​(String constraintPackage,
                                                    String constraintName,
                                                    ToLongBiFunction<A,​B> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.impactConfigurableLong(String, ToLongBiFunction)`.
      Specified by:
        `impactConfigurableLong` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### impactConfigurableBigDecimal

          default Constraint impactConfigurableBigDecimal​(String constraintPackage,
                                                          String constraintName,
                                                          BiFunction<A,​B,​BigDecimal> matchWeigher)

      Description copied from interface: `BiConstraintStream`
      As defined by `BiConstraintStream.impactConfigurableBigDecimal(String, BiFunction)`.
      Specified by:
        `impactConfigurableBigDecimal` in interface `BiConstraintStream<A,​B>`
      Parameters:
        `constraintPackage` - never null
        `constraintName` - never null
        `matchWeigher` - never null
      Returns:
        never null

    - #### impactScore

          Constraint impactScore​(String constraintPackage,
                                 String constraintName,
                                 Score<?> constraintWeight,
                                 ToIntBiFunction<A,​B> matchWeigher,
                                 ScoreImpactType impactType)

    - #### impactScoreLong

          Constraint impactScoreLong​(String constraintPackage,
                                     String constraintName,
                                     Score<?> constraintWeight,
                                     ToLongBiFunction<A,​B> matchWeigher,
                                     ScoreImpactType impactType)

    - #### impactScoreBigDecimal

          Constraint impactScoreBigDecimal​(String constraintPackage,
                                           String constraintName,
                                           Score<?> constraintWeight,
                                           BiFunction<A,​B,​BigDecimal> matchWeigher,
                                           ScoreImpactType impactType)

    - #### impactScoreConfigurable

          Constraint impactScoreConfigurable​(String constraintPackage,
                                             String constraintName,
                                             ToIntBiFunction<A,​B> matchWeigher,
                                             ScoreImpactType impactType)

    - #### impactScoreConfigurableLong

          Constraint impactScoreConfigurableLong​(String constraintPackage,
                                                 String constraintName,
                                                 ToLongBiFunction<A,​B> matchWeigher,
                                                 ScoreImpactType impactType)

    - #### impactScoreConfigurableBigDecimal

          Constraint impactScoreConfigurableBigDecimal​(String constraintPackage,
                                                       String constraintName,
                                                       BiFunction<A,​B,​BigDecimal> matchWeigher,
                                                       ScoreImpactType impactType)