OSDN Git Service

Refactor ApfFilter creation
authorHugo Benichi <hugobenichi@google.com>
Fri, 13 Oct 2017 07:32:20 +0000 (16:32 +0900)
committerHugo Benichi <hugobenichi@google.com>
Tue, 7 Nov 2017 12:42:39 +0000 (21:42 +0900)
commit7216636a621d413453947c1d40feaec9948fed73
tree0323fb2b0abc87a6ef18cc196f4754b282e35314
parent69c9402a29f1c9f958284dfeb95404f88cac2cf1
Refactor ApfFilter creation

This patch introduces a helper ApfConfiguration class for passing filter
parameters to the constructor of ApfFilter. The benefits are:
  - less parameter boilerplate across IpManager, ApfFilter, ApfTest
  - easier to add more parameters in the future (useful for hardware
    counters options and further gservices configurable options)

There is no functional changes otherwise.

Test: runtest frameworks-net
Change-Id: I47231c21df80bc36b6d4e15369748017b50b8da1
services/net/java/android/net/apf/ApfFilter.java
services/net/java/android/net/ip/IpClient.java
tests/net/java/android/net/apf/ApfTest.java