protected synchronized void handleRecieveBlock(Block block) {
		
		System.out.println("block recieved!");
		
		// here goes the code to handle the block broadcast
		
		// get the block , add it to the tree
		
		SignedBlock sb = (SignedBlock)block;
		
		try {
			
			this.blockTree.addBlock(sb);
			
			// generate a diagram
			

			
			String diagramFilename = "graphs/graph"+logPrefix+"-"+this.thisCount+"-"+ blockCounter++ +".svg";
			this.blockTree.printDOT( diagramFilename );
			
			LOGGER.log( new ThreadIDLogRecord( Level.INFO, 
											   "<a href=\"" + diagramFilename + "\">block recieved #"+ sb.serialNum +"</a>", 
											   thisCount ) );
			
		} catch (BlockHasNoPreviousException e) {
			
			LOGGER.log( new ThreadIDLogRecord( Level.INFO, 
					   "<span style=\"color:red;\">BLOCK HAS NO PREVIOUS</span>",
					thisCount ) );
			
		} catch (IOException e) {
			
			LOGGER.log( new ThreadIDLogRecord( Level.INFO, 
					   "<span style=\"color:red;\">CANT WRITE FILE</span>",
					thisCount ) );
			
		} catch (Exception e ) {
			
			LOGGER.log( new ThreadIDLogRecord( Level.INFO, 
					   "<span style=\"color:red;\">ERRAR</span>",
					thisCount ) );
			
		}
		
	}