Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

java log add function

#dd_traces.pl (C) Marko Kivij?rvi 2006
# Dummy checks
die "Specify an input file!\n" if $ARGV[0] eq "";
die "File not found!\n" unless -e $ARGV[0];
die "Incorrect file extension for a C/C++ file!\n"
    if ( $ARGV[0] !~ /(.*)\.(java)$/ );
# Constants
my $IMPORT_LOG_PACKAG = "\nimport android.util.Log;";
my $TAG;
if( $ARGV[0] !~ /BaseAdapter\.java/ && $ARGV[0] !~ /View\.java/) {
    $TAG="SWIFTTAG";
}
else {
    $TAG="SWIFTBASETAG";
}
# Parse output filename from the input filename
my $file = $ARGV[0];
my $origFile = $1."-orig.".$2;
#system( "cp $file $origFile" );
# Reset the input record separator (newline) so the entire file is read at once
undef $/;
# Read the input file
$_ = <>;                                 # All there
# Adds a tracer macro after each function definition
s/
    package #package
    \s+
    [^{;\/(\s]*\.[^{;\/(\s]*        # package name
    ;
/
    AddLogImport(tiny_mce_markeramp;)    # Print the match and add the macro
/gxe;                         # g = repeat, x = split regex to multiple lines, e = evaluate substitution
s/
    (public|private|protected)?   #api property type
    (\s+)?
    (abstract)?
    (\s+)?
    class                                     # Possible function return type
    \s+                                       # One or more empty spaces
    (\b\w+?)         &n


Ïà¹ØÎĵµ£º

java ·¾¶

java(Web)ÖÐÏà¶Ô·¾¶£¬¾ø¶Ô·¾¶ÎÊÌâ×ܽá
    javaÖÐÏà¶Ô·¾¶£¬¾ø¶Ô·¾¶ÎÊÌâ×ܽá
¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡————bohemia(³Ç)
ǰÑÔ£º
ǰһ¶Îʱ¼ä£¬ÓÉÓÚÔÚ´¦ÀíWebÓ¦ÓÃϵÄÎļþ´´½¨ÓëÒÆ¶¯µÈ£¬Òò´ËÉæ¼°µ½ºÜ¶à¹ØÓÚjava
ÖÐÏà¶Ô·¾¶£¬¾ø¶Ô·¾¶µÈÎÊÌ⡣ͬʱ£¬¶ÔÓÚWebÓ¦ÓÃÖÐµÄ ......

java ×Ö·û±àÂë

String newStr = new String(oldStr.getBytes(), "UTF-8");

javaÖеÄStringÀàÊǰ´ÕÕunicode½øÐбàÂëµÄ£¬µ±Ê¹ÓÃString(byte[] bytes, String encoding)¹¹Ôì×Ö·û´®Ê±£¬encodingËùÖ¸µÄÊÇbytesÖеÄÊý¾ÝÊǰ´ÕÕÄÇÖÖ·½Ê½±àÂëµÄ£¬¶ø²»ÊÇ×îºó²úÉúµÄStringÊÇʲô±àÂ뷽ʽ£¬»»¾ä»°Ëµ£¬ÊÇÈÃϵͳ°ÑbytesÖеÄÊý¾ÝÓÉencoding±à ......

java ͸Ã÷ͼƬ

¹ØÓÚJavaÉú³É±³¾°Í¸Ã÷µÄpngͼƬ
×î½üÓõ½Java¶¯Ì¬Éú³É±³¾°Í¸Ã÷µÄͼƬ¹¦ÄÜ£¬´ÓgifºÍpngÖÐÑ¡ÔñÁËpng¸ñʽ£¬¸öÖÐÔµÓɾͲ»ËµÁË£¬ÓÚÊǶ¯ÊÖµ½ÍøÉÏËÑË÷ÓÐÓõĴúÂë¡£ÏÖ°ÑËÑË÷½á¹û×ܽáÈçÏ£º
1. Éú³ÉpngͼƬ
int width = 400;
int height = 300;
// ´´½¨BufferedImage¶ÔÏó
BufferedImage&nb ......

java Á½¸öʱ¼ä¶ÎÓжàÉÙÌì

public static void main(String args[]){
   
     Date calr1=new Date(2010, 3,1);
     Date calr2=new Date(2010,3,31);
  
     Long n=calr2.getTime()-calr1.getTime();
     int a=(int)(n/ ......

JavaдÎļþÔ´Âë

import java.io.*;
public class FileWrite {
public static void main(String args[]) {
String outPut = "C:\\bin";
StringBuffer ab = new StringBuffer();
for(int i=6;i<=30;i++){
ab.append("http://www.test.com/joke/index_"+i+".htm\r\n&qu ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ