001/* 002 * Copyright 2010-2013 JetBrains s.r.o. 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016 017 018package jet.runtime; 019 020import jet.*; 021 022/* This file is generated by org.jetbrains.jet.generators.runtime.GenerateRanges. DO NOT EDIT! */ 023public class Ranges { 024 public static ByteRange rangeTo(byte from, byte to) { 025 return new ByteRange(from, to); 026 } 027 028 public static ShortRange rangeTo(byte from, short to) { 029 return new ShortRange(from, to); 030 } 031 032 public static IntRange rangeTo(byte from, int to) { 033 return new IntRange(from, to); 034 } 035 036 public static LongRange rangeTo(byte from, long to) { 037 return new LongRange(from, to); 038 } 039 040 public static FloatRange rangeTo(byte from, float to) { 041 return new FloatRange(from, to); 042 } 043 044 public static DoubleRange rangeTo(byte from, double to) { 045 return new DoubleRange(from, to); 046 } 047 048 public static CharRange rangeTo(byte from, char to) { 049 return new CharRange((char) from, to); 050 } 051 052 public static ShortRange rangeTo(short from, byte to) { 053 return new ShortRange(from, to); 054 } 055 056 public static ShortRange rangeTo(short from, short to) { 057 return new ShortRange(from, to); 058 } 059 060 public static IntRange rangeTo(short from, int to) { 061 return new IntRange(from, to); 062 } 063 064 public static LongRange rangeTo(short from, long to) { 065 return new LongRange(from, to); 066 } 067 068 public static FloatRange rangeTo(short from, float to) { 069 return new FloatRange(from, to); 070 } 071 072 public static DoubleRange rangeTo(short from, double to) { 073 return new DoubleRange(from, to); 074 } 075 076 public static ShortRange rangeTo(short from, char to) { 077 return new ShortRange(from, (short) to); 078 } 079 080 public static IntRange rangeTo(int from, byte to) { 081 return new IntRange(from, to); 082 } 083 084 public static IntRange rangeTo(int from, short to) { 085 return new IntRange(from, to); 086 } 087 088 public static IntRange rangeTo(int from, int to) { 089 return new IntRange(from, to); 090 } 091 092 public static LongRange rangeTo(int from, long to) { 093 return new LongRange(from, to); 094 } 095 096 public static FloatRange rangeTo(int from, float to) { 097 return new FloatRange(from, to); 098 } 099 100 public static DoubleRange rangeTo(int from, double to) { 101 return new DoubleRange(from, to); 102 } 103 104 public static IntRange rangeTo(int from, char to) { 105 return new IntRange(from, to); 106 } 107 108 public static LongRange rangeTo(long from, byte to) { 109 return new LongRange(from, to); 110 } 111 112 public static LongRange rangeTo(long from, short to) { 113 return new LongRange(from, to); 114 } 115 116 public static LongRange rangeTo(long from, int to) { 117 return new LongRange(from, to); 118 } 119 120 public static LongRange rangeTo(long from, long to) { 121 return new LongRange(from, to); 122 } 123 124 public static FloatRange rangeTo(long from, float to) { 125 return new FloatRange(from, to); 126 } 127 128 public static DoubleRange rangeTo(long from, double to) { 129 return new DoubleRange(from, to); 130 } 131 132 public static LongRange rangeTo(long from, char to) { 133 return new LongRange(from, to); 134 } 135 136 public static FloatRange rangeTo(float from, byte to) { 137 return new FloatRange(from, to); 138 } 139 140 public static FloatRange rangeTo(float from, short to) { 141 return new FloatRange(from, to); 142 } 143 144 public static FloatRange rangeTo(float from, int to) { 145 return new FloatRange(from, to); 146 } 147 148 public static FloatRange rangeTo(float from, long to) { 149 return new FloatRange(from, to); 150 } 151 152 public static FloatRange rangeTo(float from, float to) { 153 return new FloatRange(from, to); 154 } 155 156 public static DoubleRange rangeTo(float from, double to) { 157 return new DoubleRange(from, to); 158 } 159 160 public static FloatRange rangeTo(float from, char to) { 161 return new FloatRange(from, to); 162 } 163 164 public static DoubleRange rangeTo(double from, byte to) { 165 return new DoubleRange(from, to); 166 } 167 168 public static DoubleRange rangeTo(double from, short to) { 169 return new DoubleRange(from, to); 170 } 171 172 public static DoubleRange rangeTo(double from, int to) { 173 return new DoubleRange(from, to); 174 } 175 176 public static DoubleRange rangeTo(double from, long to) { 177 return new DoubleRange(from, to); 178 } 179 180 public static DoubleRange rangeTo(double from, float to) { 181 return new DoubleRange(from, to); 182 } 183 184 public static DoubleRange rangeTo(double from, double to) { 185 return new DoubleRange(from, to); 186 } 187 188 public static DoubleRange rangeTo(double from, char to) { 189 return new DoubleRange(from, to); 190 } 191 192 public static CharRange rangeTo(char from, byte to) { 193 return new CharRange(from, (char) to); 194 } 195 196 public static ShortRange rangeTo(char from, short to) { 197 return new ShortRange((short) from, to); 198 } 199 200 public static IntRange rangeTo(char from, int to) { 201 return new IntRange(from, to); 202 } 203 204 public static LongRange rangeTo(char from, long to) { 205 return new LongRange(from, to); 206 } 207 208 public static FloatRange rangeTo(char from, float to) { 209 return new FloatRange(from, to); 210 } 211 212 public static DoubleRange rangeTo(char from, double to) { 213 return new DoubleRange(from, to); 214 } 215 216 public static CharRange rangeTo(char from, char to) { 217 return new CharRange(from, to); 218 } 219 220 public static IntRange arrayIndices(int length) { 221 return new IntRange(0, length - 1); 222 } 223 224 private Ranges() {} 225}