use of android.net.apf.ApfGenerator in project android_frameworks_base by ResurrectionRemix.
the class Bpf2Apf method main.
/**
* Convert the output of "tcpdump -d" (human readable BPF program dump) piped in stdin into an
* APF program and output it via stdout.
*/
public static void main(String[] args) throws Exception {
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
String line = null;
StringBuilder responseData = new StringBuilder();
ApfGenerator gen = new ApfGenerator();
while ((line = in.readLine()) != null) convertLine(line, gen);
System.out.write(gen.generate());
}
Aggregations