亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? tree.java

?? 著名的zlib 壓縮解壓縮庫的JAVA語言實現。
?? JAVA
字號:
/* -*-mode:java; c-basic-offset:2; -*- *//*Copyright (c) 2000,2001,2002,2003 ymnk, JCraft,Inc. All rights reserved.Redistribution and use in source and binary forms, with or withoutmodification, are permitted provided that the following conditions are met:  1. Redistributions of source code must retain the above copyright notice,     this list of conditions and the following disclaimer.  2. Redistributions in binary form must reproduce the above copyright      notice, this list of conditions and the following disclaimer in      the documentation and/or other materials provided with the distribution.  3. The names of the authors may not be used to endorse or promote products     derived from this software without specific prior written permission.THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY ANDFITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOTLIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDINGNEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *//* * This program is based on zlib-1.1.3, so all credit should go authors * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu) * and contributors of zlib. */package com.jcraft.jzlib;final class Tree{  static final private int MAX_BITS=15;  static final private int BL_CODES=19;  static final private int D_CODES=30;  static final private int LITERALS=256;  static final private int LENGTH_CODES=29;  static final private int L_CODES=(LITERALS+1+LENGTH_CODES);  static final private int HEAP_SIZE=(2*L_CODES+1);  // Bit length codes must not exceed MAX_BL_BITS bits  static final int MAX_BL_BITS=7;   // end of block literal code  static final int END_BLOCK=256;   // repeat previous bit length 3-6 times (2 bits of repeat count)  static final int REP_3_6=16;   // repeat a zero length 3-10 times  (3 bits of repeat count)  static final int REPZ_3_10=17;   // repeat a zero length 11-138 times  (7 bits of repeat count)  static final int REPZ_11_138=18;   // extra bits for each length code  static final int[] extra_lbits={    0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0  };  // extra bits for each distance code  static final int[] extra_dbits={    0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13  };  // extra bits for each bit length code  static final int[] extra_blbits={    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7  };  static final byte[] bl_order={    16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15};  // The lengths of the bit length codes are sent in order of decreasing  // probability, to avoid transmitting the lengths for unused bit  // length codes.  static final int Buf_size=8*2;  // see definition of array dist_code below  static final int DIST_CODE_LEN=512;  static final byte[] _dist_code = {    0,  1,  2,  3,  4,  4,  5,  5,  6,  6,  6,  6,  7,  7,  7,  7,  8,  8,  8,  8,    8,  8,  8,  8,  9,  9,  9,  9,  9,  9,  9,  9, 10, 10, 10, 10, 10, 10, 10, 10,    10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,    11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,    12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13,    13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,    13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,    14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,    14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,    14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15,    15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,    15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,    15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,  0,  0, 16, 17,    18, 18, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 22, 22, 22, 22, 22, 22, 22, 22,    23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24,    24, 24, 24, 24, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25,    26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26,    26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 27, 27, 27, 27, 27, 27, 27, 27,    27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27,    27, 27, 27, 27, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28,    28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28,    28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28,    28, 28, 28, 28, 28, 28, 28, 28, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29,    29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29,    29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29,    29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29  };  static final byte[] _length_code={    0,  1,  2,  3,  4,  5,  6,  7,  8,  8,  9,  9, 10, 10, 11, 11, 12, 12, 12, 12,    13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16,    17, 17, 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 18, 18, 18, 18, 19, 19, 19, 19,    19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,    21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22,    22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 23, 23, 23, 23, 23, 23, 23, 23,    23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24,    24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24,    25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25,    25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 26, 26, 26, 26, 26, 26, 26, 26,    26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26,    26, 26, 26, 26, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27,    27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 28  };  static final int[] base_length = {    0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 12, 14, 16, 20, 24, 28, 32, 40, 48, 56,    64, 80, 96, 112, 128, 160, 192, 224, 0  };  static final int[] base_dist = {       0,   1,      2,     3,     4,    6,     8,    12,    16,     24,      32,  48,     64,    96,   128,  192,   256,   384,   512,    768,    1024, 1536,  2048,  3072,  4096,  6144,  8192, 12288, 16384, 24576  };  // Mapping from a distance to a distance code. dist is the distance - 1 and  // must not have side effects. _dist_code[256] and _dist_code[257] are never  // used.  static int d_code(int dist){    return ((dist) < 256 ? _dist_code[dist] : _dist_code[256+((dist)>>>7)]);  }  short[] dyn_tree;      // the dynamic tree  int     max_code;      // largest code with non zero frequency  StaticTree stat_desc;  // the corresponding static tree  // Compute the optimal bit lengths for a tree and update the total bit length  // for the current block.  // IN assertion: the fields freq and dad are set, heap[heap_max] and  //    above are the tree nodes sorted by increasing frequency.  // OUT assertions: the field len is set to the optimal bit length, the  //     array bl_count contains the frequencies for each bit length.  //     The length opt_len is updated; static_len is also updated if stree is  //     not null.  void gen_bitlen(Deflate s){    short[] tree = dyn_tree;    short[] stree = stat_desc.static_tree;    int[] extra = stat_desc.extra_bits;    int base = stat_desc.extra_base;    int max_length = stat_desc.max_length;    int h;              // heap index    int n, m;           // iterate over the tree elements    int bits;           // bit length    int xbits;          // extra bits    short f;            // frequency    int overflow = 0;   // number of elements with bit length too large    for (bits = 0; bits <= MAX_BITS; bits++) s.bl_count[bits] = 0;    // In a first pass, compute the optimal bit lengths (which may    // overflow in the case of the bit length tree).    tree[s.heap[s.heap_max]*2+1] = 0; // root of the heap    for(h=s.heap_max+1; h<HEAP_SIZE; h++){      n = s.heap[h];      bits = tree[tree[n*2+1]*2+1] + 1;      if (bits > max_length){ bits = max_length; overflow++; }      tree[n*2+1] = (short)bits;      // We overwrite tree[n*2+1] which is no longer needed      if (n > max_code) continue;  // not a leaf node      s.bl_count[bits]++;      xbits = 0;      if (n >= base) xbits = extra[n-base];      f = tree[n*2];      s.opt_len += f * (bits + xbits);      if (stree!=null) s.static_len += f * (stree[n*2+1] + xbits);    }    if (overflow == 0) return;    // This happens for example on obj2 and pic of the Calgary corpus    // Find the first bit length which could increase:    do {      bits = max_length-1;      while(s.bl_count[bits]==0) bits--;      s.bl_count[bits]--;      // move one leaf down the tree      s.bl_count[bits+1]+=2;   // move one overflow item as its brother      s.bl_count[max_length]--;      // The brother of the overflow item also moves one step up,      // but this does not affect bl_count[max_length]      overflow -= 2;    }    while (overflow > 0);    for (bits = max_length; bits != 0; bits--) {      n = s.bl_count[bits];      while (n != 0) {	m = s.heap[--h];	if (m > max_code) continue;	if (tree[m*2+1] != bits) {	  s.opt_len += ((long)bits - (long)tree[m*2+1])*(long)tree[m*2];	  tree[m*2+1] = (short)bits;	}	n--;      }    }  }  // Construct one Huffman tree and assigns the code bit strings and lengths.  // Update the total bit length for the current block.  // IN assertion: the field freq is set for all tree elements.  // OUT assertions: the fields len and code are set to the optimal bit length  //     and corresponding code. The length opt_len is updated; static_len is  //     also updated if stree is not null. The field max_code is set.  void build_tree(Deflate s){    short[] tree=dyn_tree;    short[] stree=stat_desc.static_tree;    int elems=stat_desc.elems;    int n, m;          // iterate over heap elements    int max_code=-1;   // largest code with non zero frequency    int node;          // new node being created    // Construct the initial heap, with least frequent element in    // heap[1]. The sons of heap[n] are heap[2*n] and heap[2*n+1].    // heap[0] is not used.    s.heap_len = 0;    s.heap_max = HEAP_SIZE;    for(n=0; n<elems; n++) {      if(tree[n*2] != 0) {	s.heap[++s.heap_len] = max_code = n;	s.depth[n] = 0;      }      else{	tree[n*2+1] = 0;      }    }    // The pkzip format requires that at least one distance code exists,    // and that at least one bit should be sent even if there is only one    // possible code. So to avoid special checks later on we force at least    // two codes of non zero frequency.    while (s.heap_len < 2) {      node = s.heap[++s.heap_len] = (max_code < 2 ? ++max_code : 0);      tree[node*2] = 1;      s.depth[node] = 0;      s.opt_len--; if (stree!=null) s.static_len -= stree[node*2+1];      // node is 0 or 1 so it does not have extra bits    }    this.max_code = max_code;    // The elements heap[heap_len/2+1 .. heap_len] are leaves of the tree,    // establish sub-heaps of increasing lengths:    for(n=s.heap_len/2;n>=1; n--)      s.pqdownheap(tree, n);    // Construct the Huffman tree by repeatedly combining the least two    // frequent nodes.    node=elems;                 // next internal node of the tree    do{      // n = node of least frequency      n=s.heap[1];      s.heap[1]=s.heap[s.heap_len--];      s.pqdownheap(tree, 1);      m=s.heap[1];                // m = node of next least frequency      s.heap[--s.heap_max] = n; // keep the nodes sorted by frequency      s.heap[--s.heap_max] = m;      // Create a new node father of n and m      tree[node*2] = (short)(tree[n*2] + tree[m*2]);      s.depth[node] = (byte)(Math.max(s.depth[n],s.depth[m])+1);      tree[n*2+1] = tree[m*2+1] = (short)node;      // and insert the new node in the heap      s.heap[1] = node++;      s.pqdownheap(tree, 1);    }    while(s.heap_len>=2);    s.heap[--s.heap_max] = s.heap[1];    // At this point, the fields freq and dad are set. We can now    // generate the bit lengths.    gen_bitlen(s);    // The field len is now set, we can generate the bit codes    gen_codes(tree, max_code, s.bl_count);  }  // Generate the codes for a given tree and bit counts (which need not be  // optimal).  // IN assertion: the array bl_count contains the bit length statistics for  // the given tree and the field len is set for all tree elements.  // OUT assertion: the field code is set for all tree elements of non  //     zero code length.  static void gen_codes(short[] tree, // the tree to decorate			int max_code, // largest code with non zero frequency			short[] bl_count // number of codes at each bit length			){    short[] next_code=new short[MAX_BITS+1]; // next code value for each bit length    short code = 0;            // running code value    int bits;                  // bit index    int n;                     // code index    // The distribution counts are first used to generate the code values    // without bit reversal.    for (bits = 1; bits <= MAX_BITS; bits++) {      next_code[bits] = code = (short)((code + bl_count[bits-1]) << 1);    }    // Check that the bit counts in bl_count are consistent. The last code    // must be all ones.    //Assert (code + bl_count[MAX_BITS]-1 == (1<<MAX_BITS)-1,    //        "inconsistent bit counts");    //Tracev((stderr,"\ngen_codes: max_code %d ", max_code));    for (n = 0;  n <= max_code; n++) {      int len = tree[n*2+1];      if (len == 0) continue;      // Now reverse the bits      tree[n*2] = (short)(bi_reverse(next_code[len]++, len));    }  }  // Reverse the first len bits of a code, using straightforward code (a faster  // method would use a table)  // IN assertion: 1 <= len <= 15  static int bi_reverse(int code, // the value to invert			int len   // its bit length			){    int res = 0;    do{      res|=code&1;      code>>>=1;      res<<=1;    }     while(--len>0);    return res>>>1;  }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品三级久久久久三级| 日本系列欧美系列| 日本在线不卡视频一二三区| 99riav久久精品riav| 久久久久久麻豆| 乱中年女人伦av一区二区| 91九色最新地址| 夜夜亚洲天天久久| 色婷婷av久久久久久久| 日韩美女视频一区| aaa国产一区| 亚洲视频免费观看| 99久久99久久久精品齐齐| 国产视频在线观看一区二区三区| 久久99精品国产麻豆婷婷| 欧美一区二区三区在线视频| 性感美女极品91精品| 3d动漫精品啪啪一区二区竹菊 | 成人高清视频在线| 久久久精品国产免费观看同学| 国产麻豆成人精品| 亚洲国产精品ⅴa在线观看| 国产成人免费视频网站| 国产精品视频第一区| 色美美综合视频| 天天综合天天做天天综合| 欧美卡1卡2卡| 国产乱子伦一区二区三区国色天香| 久久色.com| 色综合色综合色综合色综合色综合| 亚洲精品写真福利| 欧美日韩国产精选| 国产一区二区伦理| 亚洲精品视频一区二区| 91精品国产综合久久福利软件| 精品写真视频在线观看| 欧美一区三区四区| 国产精品一区专区| 国产一区二区按摩在线观看| 91久久精品网| 国产suv一区二区三区88区| 亚洲精品国产a| 2023国产精品自拍| 欧美日韩一区二区三区不卡| 丰满岳乱妇一区二区三区| 洋洋成人永久网站入口| 国产欧美综合色| 制服丝袜中文字幕一区| 日韩精品最新网址| 国模一区二区三区白浆| 亚洲成人自拍一区| 国产精品卡一卡二| 久久久久久久久久电影| 91精品国产综合久久精品麻豆| 99久久777色| 精品在线观看视频| 欧美激情资源网| 26uuuu精品一区二区| 国产免费成人在线视频| 成人国产在线观看| 精品在线免费视频| 蜜臀91精品一区二区三区| 国模少妇一区二区三区| 五月天欧美精品| 亚洲高清一区二区三区| 亚洲精品国产无天堂网2021| 中文字幕一区二区三区蜜月| 久久综合狠狠综合久久激情| 日韩欧美一二三区| 日韩亚洲欧美在线观看| 日韩欧美123| 成人av网站在线观看| 成人午夜激情在线| 国产河南妇女毛片精品久久久| 国产精品2024| 2020日本不卡一区二区视频| 久久亚洲精品小早川怜子| 亚洲日本在线天堂| 亚洲国产综合91精品麻豆| 亚洲一区二区在线观看视频| 亚洲不卡在线观看| 免费一级欧美片在线观看| 韩国毛片一区二区三区| 国产精品一区二区你懂的| 粉嫩aⅴ一区二区三区四区五区| 国产成人免费在线| 视频一区二区三区中文字幕| 日本女优在线视频一区二区| 国产一区二区三区在线看麻豆| 国产综合久久久久久鬼色| 国产精品亚洲а∨天堂免在线| 国产乱人伦偷精品视频不卡| 久久视频一区二区| 91精品国产日韩91久久久久久| 日韩欧美一卡二卡| 国产精品久久久久影院亚瑟| 自拍偷拍国产精品| 久久国产生活片100| 丰满放荡岳乱妇91ww| 色综合久久天天综合网| 91精品一区二区三区久久久久久 | 视频一区二区国产| 国产精品国产三级国产有无不卡| 亚洲免费伊人电影| 69av一区二区三区| 欧美日韩精品免费| 久久青草欧美一区二区三区| 中文字幕亚洲在| 日本va欧美va精品发布| proumb性欧美在线观看| 欧美巨大另类极品videosbest | 亚洲国产精品av| 亚洲国产中文字幕| 成人激情av网| 欧美成人a视频| 欧美精品日日鲁夜夜添| 在线观看中文字幕不卡| 久久免费午夜影院| 午夜久久福利影院| 欧美一二区视频| 精品福利在线导航| 亚洲国产中文字幕在线视频综合| 高清免费成人av| 日韩欧美国产1| 天天av天天翘天天综合网 | 亚洲欧美一区二区不卡| 韩国理伦片一区二区三区在线播放| 一本久久a久久免费精品不卡| 国产亚洲一区二区三区四区| 三级影片在线观看欧美日韩一区二区| 欧美精彩视频一区二区三区| 17c精品麻豆一区二区免费| 国产一区二区在线看| 26uuu国产电影一区二区| 精品一区二区三区久久| 精品久久国产老人久久综合| 久久国产婷婷国产香蕉| 日韩一区二区在线观看视频 | 一区二区三区四区高清精品免费观看 | av中文字幕一区| 国产综合久久久久久鬼色| 欧美日韩免费不卡视频一区二区三区 | 国产精品免费视频网站| 97精品超碰一区二区三区| 亚洲欧美欧美一区二区三区| 欧美精选一区二区| 国产毛片一区二区| 亚洲日本免费电影| 91精品国产91久久综合桃花| 国产精品影音先锋| 欧美一区在线视频| 国产成人精品免费视频网站| 亚洲欧洲日韩av| 日韩一区二区三区在线视频| 丰满少妇在线播放bd日韩电影| 99久精品国产| 捆绑紧缚一区二区三区视频| 日韩视频免费观看高清在线视频| 风间由美一区二区av101| 丝袜诱惑制服诱惑色一区在线观看| 2020国产精品久久精品美国| 在线欧美日韩国产| 极品少妇一区二区| 香蕉久久夜色精品国产使用方法| 久久综合色播五月| 欧美伊人久久久久久久久影院| 国模娜娜一区二区三区| 午夜精品aaa| 日韩一区二区精品葵司在线| 91麻豆高清视频| 国产乱码字幕精品高清av| 五月婷婷综合网| 亚洲欧美一区二区三区久本道91| 国产色婷婷亚洲99精品小说| 欧美精品免费视频| 欧美mv日韩mv国产网站| 欧美日韩国产高清一区二区三区| 91网址在线看| 成人精品一区二区三区中文字幕| 精品一区二区三区日韩| 日韩精品一区第一页| 亚洲18女电影在线观看| 国产一区二区伦理| 亚洲精品视频在线| 亚洲综合在线第一页| 亚洲欧美日韩成人高清在线一区| 亚洲欧美一区二区在线观看| 91亚洲精品久久久蜜桃网站| 成人18视频在线播放| 成人免费高清在线观看| av在线不卡电影| 99re成人在线| 欧美午夜精品电影| 欧美一区欧美二区| 亚洲精品伦理在线| 亚洲黄色在线视频| 亚洲国产精品一区二区www在线| 午夜精品久久久久久久久久| 香蕉成人啪国产精品视频综合网| 亚洲成av人影院在线观看网|