17ba0605dc97fb81bde8311510d27b3ccba170008Ceki Gulcu/** 27ba0605dc97fb81bde8311510d27b3ccba170008Ceki Gulcu * Copyright (c) 2004-2011 QOS.ch 388c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * All rights reserved. 47ba0605dc97fb81bde8311510d27b3ccba170008Ceki Gulcu * 588c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * Permission is hereby granted, free of charge, to any person obtaining 688c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * a copy of this software and associated documentation files (the 788c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * "Software"), to deal in the Software without restriction, including 888c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * without limitation the rights to use, copy, modify, merge, publish, 988c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * distribute, sublicense, and/or sell copies of the Software, and to 1088c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * permit persons to whom the Software is furnished to do so, subject to 1188c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * the following conditions: 127ba0605dc97fb81bde8311510d27b3ccba170008Ceki Gulcu * 1388c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * The above copyright notice and this permission notice shall be 1488c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * included in all copies or substantial portions of the Software. 157ba0605dc97fb81bde8311510d27b3ccba170008Ceki Gulcu * 1688c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 1788c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 1888c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 1988c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 2088c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 2188c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 2288c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 237ba0605dc97fb81bde8311510d27b3ccba170008Ceki Gulcu * 2488c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu */ 2588c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu 2688c4c456766193e012eb890e2208473d99b91f83Ceki Gulcupackage org.slf4j; 2788c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu 2888c4c456766193e012eb890e2208473d99b91f83Ceki Gulcuimport java.util.Random; 2988c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu 3088c4c456766193e012eb890e2208473d99b91f83Ceki Gulcupublic class Differentiator { 3188c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu 3231212435723e2dfd5d6716d1f6a7b0e66a1e6b38Ceki Gulcu static Random random = new Random(System.currentTimeMillis()); 3331212435723e2dfd5d6716d1f6a7b0e66a1e6b38Ceki Gulcu 3431212435723e2dfd5d6716d1f6a7b0e66a1e6b38Ceki Gulcu static public short getDiffentiator() { 3531212435723e2dfd5d6716d1f6a7b0e66a1e6b38Ceki Gulcu return (short) random.nextInt(Short.MAX_VALUE); 3631212435723e2dfd5d6716d1f6a7b0e66a1e6b38Ceki Gulcu } 3788c4c456766193e012eb890e2208473d99b91f83Ceki Gulcu} 38