Created
April 12, 2012 05:04
-
-
Save suapapa/2364697 to your computer and use it in GitHub Desktop.
Diagrams for MediaScannerClient of Android base framework and it's test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
PLANTUML="java -jar `realpath ~/apps/plantuml/plantuml.jar` -o `pwd`" | |
$PLANTUML MediaScannerClient.puml | |
$PLANTUML MediaScannerClient_test.puml | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@startuml | |
"startFile()" --> ===B1=== | |
--> "addStringTag(name, value)" | |
if "" then | |
-right->[value is ASCII] "handleStringTag()" | |
-down-> ===B2=== | |
else | |
-down-> "push name & value to mName & mValue" | |
-down-> ===B2=== | |
endif | |
-down-> "endFile()" | |
if "check mName & mValue" then | |
-right->[not empty] "bitwise AND all possibleEncodings(value)" #ff4500 | |
-up-> "convertValues(encodings & mLocaleEncoding)" #ff4500 | |
--> "handleStringTag()" | |
endif | |
@enduml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@startuml | |
package libgtest | |
class "testing::Test" { | |
#{abstract} SetUp() | |
#{abstract} TearDown() | |
} | |
end package | |
package libmedia | |
class MediaScannerClient { | |
#convertValues(encoding) | |
#mNames | |
#mValue | |
#mLocaleEncoding | |
+setLocale(locale) | |
+beginFile() | |
+addStringTag(name, value) | |
+endFile() | |
+{abstract} handleStringTag(name, value) | |
} | |
end package | |
package MediaScannerClient_test #43768E | |
class TestableMediaScannerClient { | |
-_results | |
-_isResultSorted | |
+addStringTagWithIdx(idx, value) | |
+addNativeTagWithIdx(idx, value) | |
+initResults() | |
+releseResults() | |
+getResult(idx) | |
+handleStringTag(name, value) | |
} | |
class MediaScannerClientTest { | |
#client | |
#SetUp() | |
#TearDown() | |
} | |
end package | |
"testing::Test" <|-- MediaScannerClientTest | |
MediaScannerClient <|-- TestableMediaScannerClient | |
MediaScannerClientTest *- TestableMediaScannerClient : client | |
@enduml |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment