00001 // IChecksum.cs - Interface to compute a data checksum 00002 // Copyright (C) 2001 Mike Krueger 00003 // 00004 // This file was translated from java, it was part of the GNU Classpath 00005 // Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc. 00006 // 00007 // This program is free software; you can redistribute it and/or 00008 // modify it under the terms of the GNU General Public License 00009 // as published by the Free Software Foundation; either version 2 00010 // of the License, or (at your option) any later version. 00011 // 00012 // This program is distributed in the hope that it will be useful, 00013 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 // GNU General Public License for more details. 00016 // 00017 // You should have received a copy of the GNU General Public License 00018 // along with this program; if not, write to the Free Software 00019 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00020 // 00021 // Linking this library statically or dynamically with other modules is 00022 // making a combined work based on this library. Thus, the terms and 00023 // conditions of the GNU General Public License cover the whole 00024 // combination. 00025 // 00026 // As a special exception, the copyright holders of this library give you 00027 // permission to link this library with independent modules to produce an 00028 // executable, regardless of the license terms of these independent 00029 // modules, and to copy and distribute the resulting executable under 00030 // terms of your choice, provided that you also meet, for each linked 00031 // independent module, the terms and conditions of the license of that 00032 // module. An independent module is a module which is not derived from 00033 // or based on this library. If you modify this library, you may extend 00034 // this exception to your version of the library, but you are not 00035 // obligated to do so. If you do not wish to do so, delete this 00036 // exception statement from your version. 00037 00038 namespace ICSharpCode.SharpZipLib.Checksums 00039 { 00040 00048 public interface IChecksum 00049 { 00053 long Value 00054 { 00055 get; 00056 } 00057 00061 void Reset(); 00062 00069 void Update(int bval); 00070 00077 void Update(byte[] buffer); 00078 00091 void Update(byte[] buf, int off, int len); 00092 } 00093 }