/*
 * Copyright (C) 2005
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
 
package estella.lib;

/** 
* Constantes necessarias
* @author Renato Demarco
* @since 20/11/2005
*/
public class Constantes
{
	public final static String GNUTELLA =       "GNUTELLA CONNECT/0.4";
	public final static String GNUTELLA_OK =    "GNUTELA OK";
	public final static String REPOSITORIO =		"compartilhados";
	public final static String LISTA_SERVENTS = "Gnutella.net";
	public final static String LOG =            "estella.log";
    
  public final static String ESTELLA =            "Estella - Cliente Gnutella 0.4";
  public final static String CONNECTION_TIMEOUT = "Tempo limite esgotado, conexao encerrada!";
	
	public final static short CONEXAO =          (short) 0xa0;
	public final static short CONEXAO_SUCEDIDA = (short) 0xa1;
	public final static short FALHA_CONEXAO =    (short) 0xa2;
	public final static short USUARIO =          (short) 0xa3;
	public final static short N_ARQUIVOS =       (short) 0xa4;
	public final static short TAM_ARQUIVOS =     (short) 0xa5;
	public final static short PROC_ARQUIVOS =    (short) 0xa6;
	public final static short QUERY_LIVRE =      (short) 0x00;
	public final static short QUERY_MIN =        (short) 0x01;
	public final static short QUERY_MED =        (short) 0x02;
	public final static short NULL =             (short) 0x00;
	public final static byte TTL =               (byte) 0x07;
	public final static String SEPARADOR = ";";
	
	public final static byte PING =      (byte) 0x00;
	public final static byte PONG =      (byte) 0x01;
	public final static byte QUERY =     (byte) 0x80;
	public final static byte QUERYHITS = (byte) 0x81;
	public final static short BYE =       (short) 0x02;
	public final static short SOCKET_TIMEOUT	= (short) 10000;
  public final static short SOCKET_SERVER_TIMEOUT = (short) 10000;
	public final static boolean SOCKET_TCPNODELAY = true;

	public final static int SERVIDOR_PORTA = (short) 6346;
	public final static int SERVIDOR_WEB_PORTA = (short) 6345;
}
