From d2c0329df022e85e12be3a5d77ea132a8b22e954 Mon Sep 17 00:00:00 2001 From: Svetlana Isakova Date: Wed, 11 Jul 2012 14:41:53 +0400 Subject: [PATCH] add interface TypeConstraints containing resulting lower and upper constraints and being constraintsBuilder's result for each type parameter --- .../calls/inference/TypeConstraints.java | 47 +++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 compiler/frontend/src/org/jetbrains/jet/lang/resolve/calls/inference/TypeConstraints.java diff --git a/compiler/frontend/src/org/jetbrains/jet/lang/resolve/calls/inference/TypeConstraints.java b/compiler/frontend/src/org/jetbrains/jet/lang/resolve/calls/inference/TypeConstraints.java new file mode 100644 index 00000000000..a8d8ea5d678 --- /dev/null +++ b/compiler/frontend/src/org/jetbrains/jet/lang/resolve/calls/inference/TypeConstraints.java @@ -0,0 +1,47 @@ +/* + * Copyright 2010-2012 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.jetbrains.jet.lang.resolve.calls.inference; + +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; +import org.jetbrains.jet.lang.types.JetType; +import org.jetbrains.jet.lang.types.Variance; + +import java.util.Set; + +/** + * @author svtk + */ +public interface TypeConstraints { + + @Nullable + JetType getLowerConstraint(); + + @Nullable + JetType getUpperConstraint(); + + @NotNull + Set getConflicts(); + + @NotNull + Variance getVariance(); + + boolean isSuccessful(); + + boolean isEmpty(); + +}