Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c8517ad814 | ||
|
|
ffb6ebb358 | ||
|
|
a4db519fcf | ||
|
|
5ff6ac32ba | ||
|
|
bc06438811 | ||
|
|
6adcbf81c6 | ||
|
|
bc24ec45af | ||
|
|
ca3b4d78a5 | ||
|
|
c1b8722b82 | ||
|
|
646627ac49 | ||
|
|
6a98deab83 | ||
|
|
92b48336ac | ||
|
|
81d545b90b | ||
|
|
9daccbb084 | ||
|
|
a47d652275 | ||
|
|
e55b5709dd | ||
|
|
9fc5d160ac | ||
|
|
544b09dc39 | ||
|
|
bc42d59471 | ||
|
|
5d46fc3e81 | ||
|
|
9a17910862 | ||
|
|
8441b88ab3 | ||
|
|
92d147ab65 | ||
|
|
1eee31316a | ||
|
|
302eccfdfe | ||
|
|
93d1fa3f19 | ||
|
|
2154e67178 | ||
|
|
de9b78035a | ||
|
|
7cb5b1ca7c | ||
|
|
85c419c3ea | ||
|
|
685bdd56f8 | ||
|
|
a32ea3568f | ||
|
|
275cd77f53 | ||
|
|
a8274d3882 | ||
|
|
8b0b58ce99 | ||
|
|
eeb5387cdf | ||
|
|
41d5f8d71f | ||
|
|
b90ef6a487 | ||
|
|
734f6eb41d | ||
|
|
4f762627cf | ||
|
|
85a1f8a505 | ||
|
|
98232dc403 | ||
|
|
e925893ad2 | ||
|
|
2f21ecd6bd | ||
|
|
d203b1b76e | ||
|
|
a15383d420 | ||
|
|
6433b9a1ae | ||
|
|
1a1446ac62 | ||
|
|
60544c7905 | ||
|
|
7e7d72f903 | ||
|
|
5a468e37f9 | ||
|
|
25cbc32ef9 | ||
|
|
310944f51e | ||
|
|
c90715b0f5 | ||
|
|
effdd8e9f3 | ||
|
|
b07d370e69 | ||
|
|
f51313411b | ||
|
|
c183327842 | ||
|
|
95d9af1281 | ||
|
|
413c42fdc1 | ||
|
|
7eca8e9528 | ||
|
|
a0deb45fa0 | ||
|
|
e19198446b | ||
|
|
e0fe27eadd | ||
|
|
83707f8bec | ||
|
|
c3d9bb0cf9 | ||
|
|
39d356841b | ||
|
|
4db67a59d7 | ||
|
|
26f5968a4a | ||
|
|
6be44cd9b5 | ||
|
|
efa3134dc6 | ||
|
|
21f2f55531 | ||
|
|
02f1ac13cf | ||
|
|
e0f634fcb6 | ||
|
|
69a0b392ff | ||
|
|
0d42dc3461 | ||
|
|
2aa6bf8c5b | ||
|
|
123145b6a8 | ||
|
|
e723174b81 | ||
|
|
c1b3c06a9d | ||
|
|
a23010b535 | ||
|
|
29e0dca2c7 | ||
|
|
a1c87535c6 | ||
|
|
a0c4718b3a | ||
|
|
7c0d82f25c | ||
|
|
5f74123c63 | ||
|
|
d0543d89b9 | ||
|
|
fd74f5eab0 | ||
|
|
1bac068c8c | ||
|
|
bbad45fbbd | ||
|
|
f2dfd2ca56 | ||
|
|
e3d6826912 | ||
|
|
b28a939792 | ||
|
|
7ba70cc84b | ||
|
|
865d8b994c | ||
|
|
1c5325711a | ||
|
|
aff7af76d4 | ||
|
|
9fecefeb4e | ||
|
|
577453a4db | ||
|
|
814dfd23fa | ||
|
|
0309864d0b | ||
|
|
947c2aa2ab | ||
|
|
0f4ce1b9b1 | ||
|
|
8a851e4f11 | ||
|
|
a298247824 | ||
|
|
acb039ee23 | ||
|
|
59e32fe696 | ||
|
|
7965ce90a6 | ||
|
|
142ca57f76 | ||
|
|
15beb0af57 | ||
|
|
14e7fbd127 | ||
|
|
144ff7dfd2 | ||
|
|
d030847992 | ||
|
|
eb1ad1f4af | ||
|
|
fc048c9bd6 | ||
|
|
c7a387df3d | ||
|
|
732f047ff7 | ||
|
|
bbeba2b733 | ||
|
|
83d2d0af02 | ||
|
|
3518464716 | ||
|
|
f9247e9114 | ||
|
|
be610059cf | ||
|
|
b12c689d4e | ||
|
|
55ae0b541a | ||
|
|
f74abd11fc | ||
|
|
8817c62ed3 | ||
|
|
d5616d63b6 | ||
|
|
9cbf6f9d56 | ||
|
|
ad66688bf9 | ||
|
|
b5281443bf | ||
|
|
c616edf9f7 | ||
|
|
aa4f8360dc | ||
|
|
99dea6d6f6 | ||
|
|
b3dcaefede | ||
|
|
9ec45096ba | ||
|
|
a3edcf845a | ||
|
|
48de3f9a8d | ||
|
|
979a3f8ee7 | ||
|
|
9c79e02cc8 | ||
|
|
3db91fb937 | ||
|
|
e9f2a6b711 | ||
|
|
955c0122cf | ||
|
|
d5f3d36d23 | ||
|
|
2c74fa3339 | ||
|
|
e3220910f5 | ||
|
|
8e97dd6972 | ||
|
|
0bf6b3fa1a | ||
|
|
6ac0599f4c | ||
|
|
f14b9accee | ||
|
|
da2ff27391 | ||
|
|
60d13ac9a9 | ||
|
|
011cac925a | ||
|
|
4d0412e5bd | ||
|
|
be30ce2c62 | ||
|
|
3c6541607c | ||
|
|
be80e42dc5 | ||
|
|
031a1d2810 | ||
|
|
ccbbb45f39 | ||
|
|
13b53c62ec | ||
|
|
8c83c7adcf | ||
|
|
5617dacfe7 | ||
|
|
ed9e20ede3 | ||
|
|
b7f91b593e | ||
|
|
4a39c5c525 | ||
|
|
fc716df189 | ||
|
|
9d108212dd | ||
|
|
e34dd65dda | ||
|
|
3386418abd | ||
|
|
c8b99e10e8 | ||
|
|
d8f8b87c54 | ||
|
|
31d3b975ea | ||
|
|
fb5de4f12a | ||
|
|
b02c0a421c | ||
|
|
2843ed749d | ||
|
|
9722a3d9b7 | ||
|
|
0d21f7a783 | ||
|
|
866b8270fe | ||
|
|
e0af9381cb | ||
|
|
e70f930929 | ||
|
|
2364a32de9 | ||
|
|
c8c0c2f42c | ||
|
|
e87056a12f | ||
|
|
cfd3153620 | ||
|
|
78c11ee41e | ||
|
|
bed4011b40 | ||
|
|
6a326072d4 | ||
|
|
ac2001142f | ||
|
|
6d71322982 | ||
|
|
3bf14799b5 | ||
|
|
aaf4264f44 | ||
|
|
b097e8070a | ||
|
|
99ad244376 | ||
|
|
99817d3e33 | ||
|
|
5a92c210f7 | ||
|
|
20aab465a8 | ||
|
|
8c8ee9bd9c | ||
|
|
5f116189e1 | ||
|
|
6da0732642 | ||
|
|
839cb6b058 | ||
|
|
a44bdd317d | ||
|
|
4b2de05e5c | ||
|
|
8e34ba7939 | ||
|
|
c5081f73be | ||
|
|
470d3cca27 | ||
|
|
7df53d9f40 | ||
|
|
051a6e582f | ||
|
|
989dc094fa | ||
|
|
0820496c45 | ||
|
|
5898aa791c | ||
|
|
10c29cee6e | ||
|
|
e25fb9a48e | ||
|
|
432d93aaa2 | ||
|
|
043ccbe6c2 | ||
|
|
e230b27e5b | ||
|
|
10c1e99335 | ||
|
|
ce83c46cba | ||
|
|
54ed1ccb80 | ||
|
|
71b0a6783a | ||
|
|
9fe216036b | ||
|
|
24c24bbffe | ||
|
|
b05232a05f | ||
|
|
da193440f2 | ||
|
|
08fb9d79f0 | ||
|
|
3fcc34436b | ||
|
|
720139660a | ||
|
|
d58dde5a95 | ||
|
|
79784787ee | ||
|
|
28fa96e153 | ||
|
|
1c1e037557 | ||
|
|
ee805d0447 | ||
|
|
c36fd98110 | ||
|
|
cb6b329ce1 | ||
|
|
733a30f310 | ||
|
|
e6aece5a05 | ||
|
|
5a158d3b61 | ||
|
|
f968f8e88a | ||
|
|
996630d0dd | ||
|
|
6a79dbdaec | ||
|
|
0c2972cf95 | ||
|
|
6945b7cd32 | ||
|
|
8dfde3332b | ||
|
|
ced5129263 | ||
|
|
eb1e6f23b0 | ||
|
|
13496ba454 | ||
|
|
d714aef47f | ||
|
|
56eecb45e4 | ||
|
|
1a332ce707 | ||
|
|
802a0b617d | ||
|
|
85206956e7 | ||
|
|
37bc68fef9 | ||
|
|
24632351ed | ||
|
|
c9dbefbe38 | ||
|
|
4fb93c41e8 | ||
|
|
81053009e0 | ||
|
|
8f4ffb4731 | ||
|
|
cb187fc7ed | ||
|
|
41c90f5467 | ||
|
|
4eef590bcf | ||
|
|
389e60b284 | ||
|
|
81afba02a0 | ||
|
|
0718e15ec9 | ||
|
|
07a3103a84 | ||
|
|
d3bab9b062 | ||
|
|
6040411c4f | ||
|
|
443310b3e5 | ||
|
|
38b149cbfc | ||
|
|
4664817d76 | ||
|
|
903bf9e3bb | ||
|
|
33dd27bb3d | ||
|
|
93971a097a | ||
|
|
820cf6ea87 | ||
|
|
42177d9251 | ||
|
|
03fd6b10b8 | ||
|
|
4836460f65 | ||
|
|
67cdd63ad4 | ||
|
|
5d866d8513 | ||
|
|
e8dc956b7d | ||
|
|
4c20c7411b | ||
|
|
af3273f9c6 | ||
|
|
3760588796 | ||
|
|
ed6e9bd469 | ||
|
|
e2a6cb02d7 | ||
|
|
6c32823a75 | ||
|
|
e867a09e25 | ||
|
|
7b4757491c | ||
|
|
c5c1768083 | ||
|
|
78cfe50597 | ||
|
|
99f4fa65ad | ||
|
|
739e0392b6 | ||
|
|
ffe823698c | ||
|
|
eff8e2037a | ||
|
|
06a78ebee0 | ||
|
|
24abd02472 | ||
|
|
a459a93d11 | ||
|
|
3d473ae5c4 | ||
|
|
bf965e8fd4 | ||
|
|
9bc6a144ec | ||
|
|
7f79248c50 | ||
|
|
c0f4b8bce7 | ||
|
|
47a38471c7 | ||
|
|
f1bef54bb4 | ||
|
|
fe56913df0 | ||
|
|
7bc5138208 | ||
|
|
637d77f95b | ||
|
|
cfeb51b422 | ||
|
|
4ae3a20b40 | ||
|
|
50881a3b2a | ||
|
|
c443093924 | ||
|
|
e74921acda | ||
|
|
e5f0402079 | ||
|
|
326d7495ac | ||
|
|
b099ec1a41 | ||
|
|
a589a2ad3f | ||
|
|
2b640f994d | ||
|
|
c3d06c4d1f | ||
|
|
a0ce6bf7f2 | ||
|
|
efa377409d | ||
|
|
65c6264428 | ||
|
|
077a8bc4d9 | ||
|
|
ad1467878f | ||
|
|
adc76d7213 | ||
|
|
a9c6086f2b | ||
|
|
3ca9cf0b62 | ||
|
|
4e287d02f9 | ||
|
|
7eeed348ca | ||
|
|
c968100b9d | ||
|
|
1b6df08df8 | ||
|
|
975b3abd98 | ||
|
|
14ba4f0c93 | ||
|
|
e3ebe25cdd | ||
|
|
c36246bded | ||
|
|
d30d6ef519 | ||
|
|
78b6c58dcd | ||
|
|
232ca60238 | ||
|
|
021650f064 | ||
|
|
1cf28d5997 | ||
|
|
334954b6a8 | ||
|
|
0fc5c13427 | ||
|
|
66f79842b7 | ||
|
|
094eed8bb3 | ||
|
|
06f746d7b0 | ||
|
|
95456166c2 | ||
|
|
206173e73a | ||
|
|
a683815540 | ||
|
|
93abec047d | ||
|
|
82732d4c35 | ||
|
|
137316d95b | ||
|
|
92ec3d31f4 | ||
|
|
b7fd424f33 | ||
|
|
ea923aa884 | ||
|
|
493cd5050d | ||
|
|
e3421d6ce4 | ||
|
|
84ac06d5df | ||
|
|
b7e29233cd | ||
|
|
17c7b5b675 | ||
|
|
f8a1aa1e77 | ||
|
|
ac011bf2d1 | ||
|
|
0e42001287 | ||
|
|
c5ba8e8fee | ||
|
|
26c8c2c6ad | ||
|
|
239ae81c78 | ||
|
|
4366723b21 | ||
|
|
e1190449c6 | ||
|
|
f5cff1c43b | ||
|
|
faf4f9bc1f | ||
|
|
605bdf5d9b | ||
|
|
2a60f884cf | ||
|
|
579cd86dab | ||
|
|
5d8b132956 | ||
|
|
10b3b514d0 | ||
|
|
16ec2b886d | ||
|
|
f406e2a258 | ||
|
|
6051271c81 | ||
|
|
7cced5a4b1 | ||
|
|
b4ba9308d2 | ||
|
|
2ada626c04 | ||
|
|
c9a7b79b50 | ||
|
|
88a64ce43d | ||
|
|
4e089c5405 | ||
|
|
30cd6b94f0 | ||
|
|
365cf562cb | ||
|
|
2078698bfa | ||
|
|
80e9274cf6 | ||
|
|
86b9e3ff3e | ||
|
|
ecead0465d | ||
|
|
e8aab5e730 | ||
|
|
0f8cf3dca0 | ||
|
|
8f1b47d4c4 | ||
|
|
76c0fc1fe7 | ||
|
|
2ff657c59d | ||
|
|
1216d9a3b7 | ||
|
|
f0ab914ca5 | ||
|
|
12537b3506 | ||
|
|
5f6d4df5b2 | ||
|
|
95dafdebe5 | ||
|
|
d23e8510db | ||
|
|
42a541e5dc | ||
|
|
7daac01c58 | ||
|
|
25827d0e9d | ||
|
|
b9fef9ad73 | ||
|
|
c33348d5fd | ||
|
|
2b3b738d3c | ||
|
|
3d7fbf8a95 | ||
|
|
132991122f | ||
|
|
43b0dd4eed | ||
|
|
c3b53776e4 | ||
|
|
79dfc5b5ba | ||
|
|
55f51cef47 | ||
|
|
d1402ad91b | ||
|
|
f6e6b91213 | ||
|
|
81dc92f449 | ||
|
|
5fd3a88b38 | ||
|
|
3bab78883b | ||
|
|
ac3523780f | ||
|
|
87850eb899 | ||
|
|
698a191586 | ||
|
|
c35bf9cabd | ||
|
|
8c21d0db04 | ||
|
|
c875ba5e54 | ||
|
|
c297fb043a | ||
|
|
bd97508a3e | ||
|
|
07a489b151 | ||
|
|
c59871300a | ||
|
|
173e91f461 | ||
|
|
12cba0242b | ||
|
|
4ed88e8fac | ||
|
|
1d9de332db | ||
|
|
72163182a0 | ||
|
|
801d7e0737 | ||
|
|
58b87f879a | ||
|
|
e518eaf742 | ||
|
|
e3346dd605 | ||
|
|
ca3cd2b12c | ||
|
|
af25a502dc | ||
|
|
b731e566e7 | ||
|
|
2f29f5bf85 | ||
|
|
6660469b43 | ||
|
|
992caa4088 | ||
|
|
31e1f23475 | ||
|
|
5b5f4b16ad | ||
|
|
dbb338ce63 | ||
|
|
1d33ded518 | ||
|
|
fe17397b38 | ||
|
|
db2cac5c62 | ||
|
|
aeec6c60b2 | ||
|
|
243720ee96 | ||
|
|
ec81dfd525 | ||
|
|
39e22de1a2 | ||
|
|
b7f7183094 | ||
|
|
911465a7ac | ||
|
|
82ed7c7111 | ||
|
|
636affe312 | ||
|
|
54aed8ec6b | ||
|
|
1d36a09731 | ||
|
|
c3eb16af85 | ||
|
|
efb4a9f8a2 | ||
|
|
31799218a9 | ||
|
|
423993b53e | ||
|
|
b2410b2625 | ||
|
|
d47832ac82 | ||
|
|
d61104d1ab | ||
|
|
00983d49cd | ||
|
|
cd77da18a0 | ||
|
|
f45900b464 | ||
|
|
cda0974d99 | ||
|
|
c1ce3e0625 | ||
|
|
de1977e1ff | ||
|
|
ec08358fcc | ||
|
|
d40a630487 | ||
|
|
f28e506060 | ||
|
|
957ad6aacb | ||
|
|
8196e9afcb | ||
|
|
2cd506d062 | ||
|
|
1627e05fa5 | ||
|
|
028a00bde6 | ||
|
|
fe843e0429 | ||
|
|
d575dcdb10 | ||
|
|
8a1314446d | ||
|
|
ca82fe5e55 | ||
|
|
374986816f | ||
|
|
5f731268b5 | ||
|
|
878480097a | ||
|
|
e033eb754d | ||
|
|
9c30879084 | ||
|
|
36b0884481 | ||
|
|
0a9054deac | ||
|
|
489ed3c4f8 | ||
|
|
d28f03573d | ||
|
|
5b9b9b5580 | ||
|
|
cb2ad03a80 | ||
|
|
4dc68854d3 | ||
|
|
c12319e103 | ||
|
|
5101bb05dc | ||
|
|
ab709a0273 | ||
|
|
ceebd341b1 | ||
|
|
cba87159ab | ||
|
|
1e3565405e | ||
|
|
24433528dc | ||
|
|
1e0a9f47b6 | ||
|
|
2cf3898f65 | ||
|
|
960f159a31 | ||
|
|
922168c86b | ||
|
|
779a07ff26 | ||
|
|
21b0212de7 | ||
|
|
0c504da18c | ||
|
|
12d2a3c935 | ||
|
|
5262253624 | ||
|
|
6f962feef7 | ||
|
|
bacab14be6 | ||
|
|
e0a786764e | ||
|
|
17bf162341 | ||
|
|
0540f775d3 | ||
|
|
2b04432a37 | ||
|
|
0a4dbbabd9 | ||
|
|
2f004502a1 | ||
|
|
8b0a7232cc | ||
|
|
fc4db3f86a | ||
|
|
58b7b274b8 | ||
|
|
d4f1d76763 | ||
|
|
250101c00a | ||
|
|
9270662842 | ||
|
|
d212e8d893 | ||
|
|
510d31544f | ||
|
|
e50a3bb8ce | ||
|
|
e626829b5c | ||
|
|
2ab8999638 | ||
|
|
8f118b7067 | ||
|
|
8a0b6bd3db | ||
|
|
bd17bf5f80 | ||
|
|
080f11c3e7 | ||
|
|
117ed40796 | ||
|
|
2188e55c5f | ||
|
|
49cc132f14 | ||
|
|
4296ed6209 | ||
|
|
8663b86fc6 | ||
|
|
c46ffd8454 | ||
|
|
cde4867b7e | ||
|
|
fdb2d535cd | ||
|
|
6e8ad7f9fc | ||
|
|
0613c8284a | ||
|
|
08fafcfced | ||
|
|
b463b61fd4 | ||
|
|
6e069a1579 | ||
|
|
17cb6af538 | ||
|
|
6c1bd61240 | ||
|
|
52049d599a | ||
|
|
57184a2c8b | ||
|
|
c767f65683 | ||
|
|
2155edd15f | ||
|
|
2b97ecf1fd | ||
|
|
6f3639702a | ||
|
|
62247033e9 | ||
|
|
ee448ad2e5 | ||
|
|
6069d1eb1c | ||
|
|
9c1aeb0dbf | ||
|
|
b9ae72aedd | ||
|
|
5180a51c74 | ||
|
|
082166cc5d | ||
|
|
94e0ff7eed | ||
|
|
5cf403a124 | ||
|
|
8a789ffe7d | ||
|
|
26df200fe4 | ||
|
|
e19bfb7f09 | ||
|
|
2502cf64ec | ||
|
|
2ccc576c69 | ||
|
|
b4ee93cd5c | ||
|
|
6cadc2d75b | ||
|
|
7b8e7a3e48 | ||
|
|
be5d7f7214 | ||
|
|
970fbdc270 | ||
|
|
ec3618deb3 | ||
|
|
4eb5b3ad08 | ||
|
|
7124d089a7 | ||
|
|
e108cd7834 | ||
|
|
90362ad0f4 | ||
|
|
e05de15865 | ||
|
|
8d86197270 | ||
|
|
984b82d4a1 | ||
|
|
7c3588275c | ||
|
|
02ab3467ed | ||
|
|
7c1ab534d8 | ||
|
|
3394148c93 | ||
|
|
c8cec5d002 | ||
|
|
ad982378ed | ||
|
|
4f50861280 | ||
|
|
f8c4ee9e6c | ||
|
|
cbe5d1069a | ||
|
|
d222d77a91 | ||
|
|
0804bfb8f6 | ||
|
|
b49dda2e18 | ||
|
|
daef06810b | ||
|
|
6786fbf569 | ||
|
|
df0386e349 | ||
|
|
e9689bb99a | ||
|
|
22d92f87ce | ||
|
|
ab4a88e4bd | ||
|
|
6983353912 | ||
|
|
d561bf2ea6 | ||
|
|
c4427313b0 | ||
|
|
4df58a5af9 | ||
|
|
7e262b6b57 | ||
|
|
20575e115c | ||
|
|
a0a730a6a9 | ||
|
|
0e1a2c78a2 | ||
|
|
6b1c41bd30 | ||
|
|
73a1373908 | ||
|
|
e5bfd5142b | ||
|
|
57c93abeef | ||
|
|
661da2f5ee | ||
|
|
a2c4710654 | ||
|
|
70a7ca5d08 | ||
|
|
28956b24da | ||
|
|
c782960949 | ||
|
|
31fcdd788a | ||
|
|
ef6431afbc | ||
|
|
5b227ee089 | ||
|
|
8de21d751e | ||
|
|
eb79cffb34 | ||
|
|
2c1f1c6828 | ||
|
|
c9f3510745 | ||
|
|
309b425e2c | ||
|
|
7add8bcc39 | ||
|
|
c5db820e1d | ||
|
|
119140a6bc | ||
|
|
6bc741d0b0 | ||
|
|
1682e06d24 | ||
|
|
729600917c | ||
|
|
141bddd504 | ||
|
|
ee53b48d96 | ||
|
|
7ec0492c0c | ||
|
|
5f35de732d | ||
|
|
bb667a3d37 | ||
|
|
82fcf044cf | ||
|
|
065d3594ac | ||
|
|
5aed05adc4 | ||
|
|
8f7a420ae3 | ||
|
|
29641c370e | ||
|
|
efb2484569 | ||
|
|
4c958bb333 | ||
|
|
6ca1fd6097 | ||
|
|
52087c3b9e | ||
|
|
5c22b2731b | ||
|
|
63f4a8229a | ||
|
|
08149e9e7e | ||
|
|
6fb08cfa99 | ||
|
|
a28feee4dc | ||
|
|
a3923f7a3a | ||
|
|
d7f73d9207 | ||
|
|
c182c97390 | ||
|
|
64e85478bd | ||
|
|
0402909473 | ||
|
|
6d40e00126 | ||
|
|
85282a2a34 | ||
|
|
14a8b1a66d | ||
|
|
e9f03ed115 | ||
|
|
1a86849463 | ||
|
|
9dac625117 | ||
|
|
4099e233d1 | ||
|
|
d68f9942eb | ||
|
|
d57fa48058 | ||
|
|
07b6434689 | ||
|
|
1566807d4d | ||
|
|
f4eee6f58e | ||
|
|
dc05e809f5 | ||
|
|
7d158bf3e2 | ||
|
|
7d460a6069 | ||
|
|
c6056dd033 | ||
|
|
29a77307a1 | ||
|
|
6839e60ff9 | ||
|
|
0473c5abc2 | ||
|
|
504e0a76d5 | ||
|
|
538e6ed98d | ||
|
|
516ca15abd | ||
|
|
c5485d0e4d | ||
|
|
7a3c6daf3d | ||
|
|
00aa51e082 | ||
|
|
d36195c89b | ||
|
|
28d2eaa527 | ||
|
|
f6b57a4b09 | ||
|
|
386877e91e | ||
|
|
5a0c43b7fe | ||
|
|
dbc22e7d87 | ||
|
|
9685f05c53 | ||
|
|
6fb9d77f70 | ||
|
|
4c4664f4f6 | ||
|
|
bbb7c38416 | ||
|
|
701bb898c5 | ||
|
|
1fa625e948 | ||
|
|
d4e429fdca | ||
|
|
3dc1e2d4ee | ||
|
|
9e8b222181 | ||
|
|
3d22d68548 | ||
|
|
afe92c04e0 | ||
|
|
d6d4998f3a | ||
|
|
f77e19556a | ||
|
|
fd04610e6c | ||
|
|
cb687d51e4 | ||
|
|
e37328e1f5 | ||
|
|
d10990e337 | ||
|
|
d9d0e1ff63 | ||
|
|
5c3c66ec6e | ||
|
|
e62614cb18 | ||
|
|
4615418e38 | ||
|
|
5ed74d18d8 | ||
|
|
586e6972a1 | ||
|
|
f1090e046d | ||
|
|
32a8d308a1 | ||
|
|
7ba7cc77bf | ||
|
|
4ef8d8c7ef | ||
|
|
6a43b55809 | ||
|
|
323f29f4a7 | ||
|
|
825d285361 | ||
|
|
b98c08ef16 | ||
|
|
03ec846b96 | ||
|
|
c9b8a880f3 | ||
|
|
efac779874 | ||
|
|
031c755e1d | ||
|
|
35a0e68e2d | ||
|
|
cd537649a0 | ||
|
|
d1e3255219 | ||
|
|
0c215013f3 | ||
|
|
5c8fe0998c | ||
|
|
08361e5d4d | ||
|
|
12b053f2c1 | ||
|
|
557bc63f95 | ||
|
|
085e52d4b6 | ||
|
|
24332576e2 | ||
|
|
15ee6f344f | ||
|
|
c2eec8064b | ||
|
|
6e3434b7f1 | ||
|
|
c59fdcf696 | ||
|
|
17cc72bd36 | ||
|
|
03877e3e2d | ||
|
|
6d3d9f001e | ||
|
|
4462ced6ae | ||
|
|
bc0370303f | ||
|
|
7bcc4dbbad | ||
|
|
7e2f97d900 | ||
|
|
ce757da3c0 | ||
|
|
6373bd1f47 | ||
|
|
d1373eab9e | ||
|
|
7b4304224b | ||
|
|
f3cb02b6b2 | ||
|
|
65c1996c47 | ||
|
|
7d5a2316b0 | ||
|
|
5fd3cde33f | ||
|
|
8fd1e85bcf | ||
|
|
68a8e75946 | ||
|
|
2d44b20352 | ||
|
|
e3faadef3b | ||
|
|
944935faba | ||
|
|
b879f2d98e | ||
|
|
afdb560ccb | ||
|
|
3f1654f76b | ||
|
|
4ff9c63876 | ||
|
|
2190a320e1 | ||
|
|
348a918ab9 | ||
|
|
4b608d986e | ||
|
|
ab2dc8103e | ||
|
|
648535f17b | ||
|
|
1805d5fcf6 | ||
|
|
d4b847acc6 | ||
|
|
cae849f1c1 | ||
|
|
44232ef93f | ||
|
|
3e81fab284 | ||
|
|
108bee3010 | ||
|
|
3457475c51 | ||
|
|
9524b305c6 | ||
|
|
7bb5d5ddfc | ||
|
|
ff0b272fa4 | ||
|
|
5eb9af56c2 | ||
|
|
b49a002896 | ||
|
|
c9efb8b93b | ||
|
|
40ff40b25d | ||
|
|
bd6e6f6140 | ||
|
|
d55544e2df | ||
|
|
d2a7e82f44 | ||
|
|
afb458daf6 | ||
|
|
78bba740c2 | ||
|
|
c434e15c06 | ||
|
|
4250351f5b | ||
|
|
2b3fb068df | ||
|
|
bf3a0c4fb8 | ||
|
|
a0e5e77dcb | ||
|
|
f9f537b56a | ||
|
|
5de7b09967 | ||
|
|
b2b2f3095f | ||
|
|
23f6f90b56 | ||
|
|
474ed831c0 | ||
|
|
b10736804b | ||
|
|
6bce5197b0 | ||
|
|
bd5e1d53d6 | ||
|
|
fa75037ab3 | ||
|
|
34d12ee6d8 | ||
|
|
a050e7c411 | ||
|
|
c00177394d | ||
|
|
a0ac0d9348 |
No files matched your search
@@ -0,0 +1,10 @@
|
|||||||
|
---
|
||||||
|
name: 新機能用テンプレート
|
||||||
|
about: 新規開発Issue用テンプレート
|
||||||
|
title: ''
|
||||||
|
labels: ''
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
WIP
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
*.iml
|
||||||
|
.gradle
|
||||||
|
/local.properties
|
||||||
|
/.idea/caches
|
||||||
|
/.idea/libraries
|
||||||
|
/.idea/modules.xml
|
||||||
|
/.idea/workspace.xml
|
||||||
|
/.idea/navEditor.xml
|
||||||
|
/.idea/assetWizardSettings.xml
|
||||||
|
.DS_Store
|
||||||
|
/build
|
||||||
|
/captures
|
||||||
|
.externalNativeBuild
|
||||||
|
.cxx
|
||||||
|
local.properties
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
# Default ignored files
|
||||||
|
/shelf/
|
||||||
|
/workspace.xml
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Lacerta
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="CompilerConfiguration">
|
||||||
|
<bytecodeTargetLevel target="17" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="deploymentTargetDropDown">
|
||||||
|
<runningDeviceTargetSelectedWithDropDown>
|
||||||
|
<Target>
|
||||||
|
<type value="RUNNING_DEVICE_TARGET" />
|
||||||
|
<deviceKey>
|
||||||
|
<Key>
|
||||||
|
<type value="SERIAL_NUMBER" />
|
||||||
|
<value value="ZY227DCBHN" />
|
||||||
|
</Key>
|
||||||
|
</deviceKey>
|
||||||
|
</Target>
|
||||||
|
</runningDeviceTargetSelectedWithDropDown>
|
||||||
|
<timeTargetWasSelectedWithDropDown value="2023-12-21T04:53:14.729902700Z" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="deploymentTargetSelector">
|
||||||
|
<selectionStates>
|
||||||
|
<SelectionState runConfigName="app">
|
||||||
|
<option name="selectionMode" value="DROPDOWN" />
|
||||||
|
<DropdownSelection timestamp="2023-12-18T03:36:14.973846Z">
|
||||||
|
<Target type="DEFAULT_BOOT">
|
||||||
|
<handle>
|
||||||
|
<DeviceId pluginId="PhysicalDevice" identifier="serial=ZY22H7V3G7" />
|
||||||
|
</handle>
|
||||||
|
</Target>
|
||||||
|
</DropdownSelection>
|
||||||
|
<DialogSelection />
|
||||||
|
</SelectionState>
|
||||||
|
</selectionStates>
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="GradleMigrationSettings" migrationVersion="1" />
|
||||||
|
<component name="GradleSettings">
|
||||||
|
<option name="linkedExternalProjectsSettings">
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="testRunner" value="GRADLE" />
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||||
|
<option name="gradleJvm" value="jbr-17" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$" />
|
||||||
|
<option value="$PROJECT_DIR$/app" />
|
||||||
|
<option value="$PROJECT_DIR$/component" />
|
||||||
|
<option value="$PROJECT_DIR$/component/common" />
|
||||||
|
<option value="$PROJECT_DIR$/component/scanner" />
|
||||||
|
<option value="$PROJECT_DIR$/component/viewer" />
|
||||||
|
<option value="$PROJECT_DIR$/data" />
|
||||||
|
<option value="$PROJECT_DIR$/feature" />
|
||||||
|
<option value="$PROJECT_DIR$/feature/common" />
|
||||||
|
<option value="$PROJECT_DIR$/feature/debug" />
|
||||||
|
<option value="$PROJECT_DIR$/feature/home" />
|
||||||
|
<option value="$PROJECT_DIR$/feature/library" />
|
||||||
|
<option value="$PROJECT_DIR$/feature/scan" />
|
||||||
|
<option value="$PROJECT_DIR$/feature/search" />
|
||||||
|
<option value="$PROJECT_DIR$/model" />
|
||||||
|
<option value="$PROJECT_DIR$/processor" />
|
||||||
|
<option value="$PROJECT_DIR$/shared" />
|
||||||
|
<option value="$PROJECT_DIR$/shared/icon" />
|
||||||
|
<option value="$PROJECT_DIR$/shared/ui" />
|
||||||
|
<option value="$PROJECT_DIR$/source" />
|
||||||
|
<option value="$PROJECT_DIR$/utils" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
<option name="resolveExternalAnnotations" value="false" />
|
||||||
|
</GradleProjectSettings>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectMigrations">
|
||||||
|
<option name="MigrateToGradleLocalJavaHome">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
<project version="4">
|
||||||
|
<component name="ExternalStorageConfigurationManager" enabled="true" />
|
||||||
|
<component name="ProjectRootManager" version="2" languageLevel="JDK_17" project-jdk-name="jbr-17" project-jdk-type="JavaSDK">
|
||||||
|
<output url="file://$PROJECT_DIR$/build/classes" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectType">
|
||||||
|
<option name="id" value="Android" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -1,2 +1,17 @@
|
|||||||
# Lacerta
|
# Lacerta
|
||||||
WIP
|
WIP
|
||||||
|
## モジュール設計
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## メモ
|
||||||
|
- アイコン: Google Material Icons https://fonts.google.com/icons (Weight:300, Grade:0, Optical size: 24px)
|
||||||
|
|
||||||
|
## コーディング規則/推奨(WIP)
|
||||||
|
### 規則
|
||||||
|
- `// TODO`コメントには任意のsuffixを付ける
|
||||||
|
- 全員が同じ`// TODO:`を使っていると検索がむずかしくなるため
|
||||||
|
- (例: `// TODO-rca:`)
|
||||||
|
### 推奨
|
||||||
|
- マジックナンバーは控える(必要な場合もあるので)
|
||||||
|
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
/build
|
||||||
@@ -0,0 +1,97 @@
|
|||||||
|
plugins {
|
||||||
|
id 'com.android.application'
|
||||||
|
id 'com.google.dagger.hilt.android'
|
||||||
|
}
|
||||||
|
|
||||||
|
android {
|
||||||
|
namespace 'one.nem.lacerta'
|
||||||
|
compileSdk 34
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
applicationId "one.nem.lacerta"
|
||||||
|
minSdk 26
|
||||||
|
targetSdk 33
|
||||||
|
|
||||||
|
// ベータ, Internal, Release問わず毎回インクリメントする
|
||||||
|
// https://developer.android.com/studio/publish/versioning#versioningsettings
|
||||||
|
versionCode 1
|
||||||
|
versionName "0.1.0"
|
||||||
|
|
||||||
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
debug { // 開発メンバー用
|
||||||
|
debuggable true
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
|
||||||
|
matchingFallbacks = ['release']
|
||||||
|
}
|
||||||
|
internal_release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
|
||||||
|
matchingFallbacks = ['release']
|
||||||
|
}
|
||||||
|
beta_release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
|
||||||
|
matchingFallbacks = ['release']
|
||||||
|
}
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
implementation libs.androidx.appcompat
|
||||||
|
implementation libs.com.google.android.material
|
||||||
|
implementation libs.androidx.constraintlayout
|
||||||
|
testImplementation libs.junit
|
||||||
|
androidTestImplementation libs.androidx.test.ext.junit
|
||||||
|
androidTestImplementation libs.androidx.test.espresso.core
|
||||||
|
|
||||||
|
// 内部モジュール
|
||||||
|
// Feature
|
||||||
|
implementation project(':feature:home')
|
||||||
|
implementation project(':feature:search')
|
||||||
|
implementation project(':feature:library')
|
||||||
|
implementation project(':feature:scan')
|
||||||
|
implementation project(':feature:debug') // デバッグメニュー
|
||||||
|
|
||||||
|
// // Component
|
||||||
|
// implementation project(':component:common')
|
||||||
|
// implementation project(':component:scanner')
|
||||||
|
// implementation project(':component:viewer')
|
||||||
|
|
||||||
|
// // Data
|
||||||
|
// implementation project(':data:repository')
|
||||||
|
//
|
||||||
|
// // Source
|
||||||
|
// implementation project(':data:source:database')
|
||||||
|
// implementation project(':data:source:preference')
|
||||||
|
//
|
||||||
|
implementation project(':data')
|
||||||
|
|
||||||
|
implementation project(':shared:ui')
|
||||||
|
|
||||||
|
implementation project(':shared:icon')
|
||||||
|
|
||||||
|
// Hilt (DI)
|
||||||
|
implementation libs.com.google.dagger.hilt.android
|
||||||
|
annotationProcessor libs.com.google.dagger.hilt.compiler
|
||||||
|
|
||||||
|
// Navigation
|
||||||
|
implementation libs.navigation.fragment
|
||||||
|
implementation libs.navigation.ui
|
||||||
|
implementation libs.navigation.dynamic.features.fragment
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package one.nem.lacerta;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import androidx.test.platform.app.InstrumentationRegistry;
|
||||||
|
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||||
|
assertEquals("one.nem.lacerta", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,48 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
|
<uses-feature
|
||||||
|
android:name="android.hardware.camera"
|
||||||
|
android:required="false" />
|
||||||
|
<uses-permission android:name="android.permission.CAMERA" />
|
||||||
|
|
||||||
|
<queries>
|
||||||
|
<intent>
|
||||||
|
<action android:name="android.media.action.IMAGE_CAPTURE" />
|
||||||
|
</intent>
|
||||||
|
</queries>
|
||||||
|
|
||||||
|
<application
|
||||||
|
android:allowBackup="true"
|
||||||
|
android:dataExtractionRules="@xml/data_extraction_rules"
|
||||||
|
android:fullBackupContent="@xml/backup_rules"
|
||||||
|
android:icon="@mipmap/ic_launcher"
|
||||||
|
android:name=".LacertaApplication"
|
||||||
|
android:label="@string/app_name"
|
||||||
|
android:roundIcon="@mipmap/ic_launcher_round"
|
||||||
|
android:supportsRtl="true"
|
||||||
|
android:theme="@style/Theme.Lacerta"
|
||||||
|
tools:targetApi="31">
|
||||||
|
<activity
|
||||||
|
android:name=".MainActivity"
|
||||||
|
android:exported="true">
|
||||||
|
<intent-filter>
|
||||||
|
<action android:name="android.intent.action.MAIN" />
|
||||||
|
|
||||||
|
<category android:name="android.intent.category.LAUNCHER" />
|
||||||
|
</intent-filter>
|
||||||
|
</activity>
|
||||||
|
|
||||||
|
<provider
|
||||||
|
android:name="androidx.core.content.FileProvider"
|
||||||
|
android:authorities="one.nem.lacerta.provider"
|
||||||
|
android:exported="false"
|
||||||
|
android:grantUriPermissions="true">
|
||||||
|
<meta-data
|
||||||
|
android:name="android.support.FILE_PROVIDER_PATHS"
|
||||||
|
android:resource="@xml/file_paths" />
|
||||||
|
</provider>
|
||||||
|
</application>
|
||||||
|
|
||||||
|
</manifest>
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package one.nem.lacerta;
|
||||||
|
|
||||||
|
import android.app.Application;
|
||||||
|
|
||||||
|
import com.google.android.material.color.DynamicColors;
|
||||||
|
|
||||||
|
import dagger.hilt.android.HiltAndroidApp;
|
||||||
|
|
||||||
|
@HiltAndroidApp
|
||||||
|
public class LacertaApplication extends Application {
|
||||||
|
@Override
|
||||||
|
public void onCreate() {
|
||||||
|
super.onCreate();
|
||||||
|
|
||||||
|
// DynamicColorを有効化
|
||||||
|
DynamicColors.applyToActivitiesIfAvailable(this);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
package one.nem.lacerta;
|
||||||
|
|
||||||
|
import androidx.appcompat.app.AppCompatActivity;
|
||||||
|
import androidx.fragment.app.FragmentManager;
|
||||||
|
import androidx.navigation.NavController;
|
||||||
|
import androidx.navigation.fragment.NavHostFragment;
|
||||||
|
import androidx.navigation.ui.NavigationUI;
|
||||||
|
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import com.google.android.material.bottomnavigation.BottomNavigationView;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
import dagger.hilt.android.AndroidEntryPoint;
|
||||||
|
import javax.inject.Inject;
|
||||||
|
|
||||||
|
@AndroidEntryPoint
|
||||||
|
public class MainActivity extends AppCompatActivity {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
setContentView(R.layout.activity_main);
|
||||||
|
|
||||||
|
// Debug
|
||||||
|
FragmentManager supportFragmentManager = getSupportFragmentManager();
|
||||||
|
|
||||||
|
NavHostFragment navHostFragment = (NavHostFragment) supportFragmentManager.findFragmentById(R.id.nav_host_fragment);
|
||||||
|
NavController navController = navHostFragment.getNavController();
|
||||||
|
BottomNavigationView bottomNavigationView = findViewById(R.id.bottom_nav);
|
||||||
|
|
||||||
|
NavigationUI.setupWithNavController(bottomNavigationView, navController);
|
||||||
|
|
||||||
|
Toast.makeText(this, "testMessage", Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,170 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:width="108dp"
|
||||||
|
android:height="108dp"
|
||||||
|
android:viewportWidth="108"
|
||||||
|
android:viewportHeight="108">
|
||||||
|
<path
|
||||||
|
android:fillColor="#3DDC84"
|
||||||
|
android:pathData="M0,0h108v108h-108z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M9,0L9,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,0L19,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M29,0L29,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M39,0L39,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M49,0L49,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M59,0L59,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M69,0L69,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M79,0L79,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M89,0L89,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M99,0L99,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,9L108,9"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,19L108,19"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,29L108,29"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,39L108,39"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,49L108,49"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,59L108,59"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,69L108,69"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,79L108,79"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,89L108,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,99L108,99"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,29L89,29"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,39L89,39"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,49L89,49"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,59L89,59"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,69L89,69"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,79L89,79"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M29,19L29,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M39,19L39,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M49,19L49,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M59,19L59,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M69,19L69,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M79,19L79,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
</vector>
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:aapt="http://schemas.android.com/aapt"
|
||||||
|
android:width="108dp"
|
||||||
|
android:height="108dp"
|
||||||
|
android:viewportWidth="108"
|
||||||
|
android:viewportHeight="108">
|
||||||
|
<path android:pathData="M31,63.928c0,0 6.4,-11 12.1,-13.1c7.2,-2.6 26,-1.4 26,-1.4l38.1,38.1L107,108.928l-32,-1L31,63.928z">
|
||||||
|
<aapt:attr name="android:fillColor">
|
||||||
|
<gradient
|
||||||
|
android:endX="85.84757"
|
||||||
|
android:endY="92.4963"
|
||||||
|
android:startX="42.9492"
|
||||||
|
android:startY="49.59793"
|
||||||
|
android:type="linear">
|
||||||
|
<item
|
||||||
|
android:color="#44000000"
|
||||||
|
android:offset="0.0" />
|
||||||
|
<item
|
||||||
|
android:color="#00000000"
|
||||||
|
android:offset="1.0" />
|
||||||
|
</gradient>
|
||||||
|
</aapt:attr>
|
||||||
|
</path>
|
||||||
|
<path
|
||||||
|
android:fillColor="#FFFFFF"
|
||||||
|
android:fillType="nonZero"
|
||||||
|
android:pathData="M65.3,45.828l3.8,-6.6c0.2,-0.4 0.1,-0.9 -0.3,-1.1c-0.4,-0.2 -0.9,-0.1 -1.1,0.3l-3.9,6.7c-6.3,-2.8 -13.4,-2.8 -19.7,0l-3.9,-6.7c-0.2,-0.4 -0.7,-0.5 -1.1,-0.3C38.8,38.328 38.7,38.828 38.9,39.228l3.8,6.6C36.2,49.428 31.7,56.028 31,63.928h46C76.3,56.028 71.8,49.428 65.3,45.828zM43.4,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2c-0.3,-0.7 -0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C45.3,56.528 44.5,57.328 43.4,57.328L43.4,57.328zM64.6,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2s-0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C66.5,56.528 65.6,57.328 64.6,57.328L64.6,57.328z"
|
||||||
|
android:strokeWidth="1"
|
||||||
|
android:strokeColor="#00000000" />
|
||||||
|
</vector>
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:theme="@style/Theme.Lacerta"
|
||||||
|
tools:context=".MainActivity">
|
||||||
|
|
||||||
|
<androidx.fragment.app.FragmentContainerView
|
||||||
|
android:id="@+id/nav_host_fragment"
|
||||||
|
android:name="androidx.navigation.fragment.NavHostFragment"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
app:defaultNavHost="true"
|
||||||
|
app:layout_constraintBottom_toTopOf="@+id/bottom_nav"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:navGraph="@navigation/main_nav"
|
||||||
|
tools:layout="@layout/fragment_debug_menu_container" />
|
||||||
|
|
||||||
|
<com.google.android.material.bottomnavigation.BottomNavigationView
|
||||||
|
android:id="@+id/bottom_nav"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:menu="@menu/bottom_nav_menu"/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@id/feature_home_navigation"
|
||||||
|
android:icon="@drawable/home_24px"
|
||||||
|
android:title="Home"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@id/feature_library_navigation"
|
||||||
|
android:icon="@drawable/folder_24px"
|
||||||
|
android:title="Library"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@id/feature_debug_navigation"
|
||||||
|
android:icon="@drawable/developer_mode_24px"
|
||||||
|
android:title="Debug menu"/>
|
||||||
|
|
||||||
|
|
||||||
|
</menu>
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<background android:drawable="@drawable/ic_launcher_background" />
|
||||||
|
<foreground android:drawable="@drawable/ic_launcher_foreground" />
|
||||||
|
<monochrome android:drawable="@drawable/ic_launcher_foreground" />
|
||||||
|
</adaptive-icon>
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<background android:drawable="@drawable/ic_launcher_background" />
|
||||||
|
<foreground android:drawable="@drawable/ic_launcher_foreground" />
|
||||||
|
<monochrome android:drawable="@drawable/ic_launcher_foreground" />
|
||||||
|
</adaptive-icon>
|
||||||
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 2.8 KiB |
|
After Width: | Height: | Size: 982 B |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 3.8 KiB |
|
After Width: | Height: | Size: 2.8 KiB |
|
After Width: | Height: | Size: 5.8 KiB |
|
After Width: | Height: | Size: 3.8 KiB |
|
After Width: | Height: | Size: 7.6 KiB |
@@ -0,0 +1,14 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<navigation xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:id="@+id/app_main_nav"
|
||||||
|
app:startDestination="@id/feature_debug_navigation">
|
||||||
|
|
||||||
|
<include app:graph="@navigation/feature_debug_navigation" />
|
||||||
|
|
||||||
|
<include app:graph="@navigation/feature_library_navigation" />
|
||||||
|
|
||||||
|
<include app:graph="@navigation/feature_home_navigation" />
|
||||||
|
|
||||||
|
|
||||||
|
</navigation>
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
<resources>
|
||||||
|
<string name="app_name">Lacerta</string>
|
||||||
|
</resources>
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?><!--
|
||||||
|
Sample backup rules file; uncomment and customize as necessary.
|
||||||
|
See https://developer.android.com/guide/topics/data/autobackup
|
||||||
|
for details.
|
||||||
|
Note: This file is ignored for devices older that API 31
|
||||||
|
See https://developer.android.com/about/versions/12/backup-restore
|
||||||
|
-->
|
||||||
|
<full-backup-content>
|
||||||
|
<!--
|
||||||
|
<include domain="sharedpref" path="."/>
|
||||||
|
<exclude domain="sharedpref" path="device.xml"/>
|
||||||
|
-->
|
||||||
|
</full-backup-content>
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?><!--
|
||||||
|
Sample data extraction rules file; uncomment and customize as necessary.
|
||||||
|
See https://developer.android.com/about/versions/12/backup-restore#xml-changes
|
||||||
|
for details.
|
||||||
|
-->
|
||||||
|
<data-extraction-rules>
|
||||||
|
<cloud-backup>
|
||||||
|
<!-- TODO: Use <include> and <exclude> to control what is backed up.
|
||||||
|
<include .../>
|
||||||
|
<exclude .../>
|
||||||
|
-->
|
||||||
|
</cloud-backup>
|
||||||
|
<!--
|
||||||
|
<device-transfer>
|
||||||
|
<include .../>
|
||||||
|
<exclude .../>
|
||||||
|
</device-transfer>
|
||||||
|
-->
|
||||||
|
</data-extraction-rules>
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<paths>
|
||||||
|
<cache-path name="cache" path="." />
|
||||||
|
</paths>
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package one.nem.lacerta;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example local unit test, which will execute on the development machine (host).
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
public class ExampleUnitTest {
|
||||||
|
@Test
|
||||||
|
public void addition_isCorrect() {
|
||||||
|
assertEquals(4, 2 + 2);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
||||||
|
plugins {
|
||||||
|
id 'com.android.application' version '8.0.2' apply false
|
||||||
|
id 'com.google.dagger.hilt.android' version '2.44' apply false
|
||||||
|
id 'com.android.library' version '8.0.2' apply false
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
/build
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
plugins {
|
||||||
|
alias(libs.plugins.com.android.library)
|
||||||
|
}
|
||||||
|
|
||||||
|
android {
|
||||||
|
namespace 'one.nem.lacerta.component.common'
|
||||||
|
compileSdk 33
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
minSdk 26
|
||||||
|
|
||||||
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
consumerProguardFiles "consumer-rules.pro"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
|
||||||
|
implementation libs.androidx.appcompat
|
||||||
|
implementation libs.com.google.android.material
|
||||||
|
testImplementation libs.junit
|
||||||
|
androidTestImplementation libs.androidx.test.ext.junit
|
||||||
|
androidTestImplementation libs.androidx.test.espresso.core
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package one.nem.lacerta.component.common;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import androidx.test.platform.app.InstrumentationRegistry;
|
||||||
|
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||||
|
assertEquals("one.nem.lacerta.component.common.test", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
</manifest>
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package one.nem.lacerta.component.common;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example local unit test, which will execute on the development machine (host).
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
public class ExampleUnitTest {
|
||||||
|
@Test
|
||||||
|
public void addition_isCorrect() {
|
||||||
|
assertEquals(4, 2 + 2);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
/build
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
plugins {
|
||||||
|
alias(libs.plugins.com.android.library)
|
||||||
|
}
|
||||||
|
|
||||||
|
android {
|
||||||
|
namespace 'one.nem.lacerta.component.scanner'
|
||||||
|
compileSdk 33
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
minSdk 26
|
||||||
|
|
||||||
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
consumerProguardFiles "consumer-rules.pro"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
|
||||||
|
implementation libs.androidx.appcompat
|
||||||
|
implementation libs.com.google.android.material
|
||||||
|
testImplementation libs.junit
|
||||||
|
androidTestImplementation libs.androidx.test.ext.junit
|
||||||
|
androidTestImplementation libs.androidx.test.espresso.core
|
||||||
|
|
||||||
|
implementation 'com.websitebeaver:documentscanner:1.0.0'
|
||||||
|
|
||||||
|
implementation project(':shared:ui')
|
||||||
|
implementation project(':model')
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package one.nem.lacerta.component.scanner;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import androidx.test.platform.app.InstrumentationRegistry;
|
||||||
|
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||||
|
assertEquals("one.nem.lacerta.component.scanner.test", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
</manifest>
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
package one.nem.lacerta.component.scanner;
|
||||||
|
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
public class CaptureResultAdapter extends RecyclerView.Adapter<CaptureResultAdapter.ViewHolder> {
|
||||||
|
private final ArrayList<CapturedData> results;
|
||||||
|
|
||||||
|
public CaptureResultAdapter(ArrayList<CapturedData> results) {
|
||||||
|
this.results = results;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CaptureResultAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
|
||||||
|
View view = LayoutInflater.from(parent.getContext()).inflate(R.layout.list_item_scanner_component_manager_stub, parent, false);
|
||||||
|
return new CaptureResultAdapter.ViewHolder(view);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onBindViewHolder(CaptureResultAdapter.ViewHolder holder, int position) {
|
||||||
|
CapturedData result = results.get(position);
|
||||||
|
holder.textViewPath.setText(result.getPath());
|
||||||
|
holder.textViewResolutionHeight.setText(result.getResolutionHeight());
|
||||||
|
holder.textViewResolutionWidth.setText(result.getResolutionWidth());
|
||||||
|
holder.imageView.setImageBitmap(result.getBitmap());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getItemCount() {
|
||||||
|
return results.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
public class ViewHolder extends RecyclerView.ViewHolder {
|
||||||
|
|
||||||
|
public TextView textViewPath;
|
||||||
|
public TextView textViewResolutionHeight;
|
||||||
|
public TextView textViewResolutionWidth;
|
||||||
|
public ImageView imageView;
|
||||||
|
|
||||||
|
public ViewHolder(View view) {
|
||||||
|
super(view);
|
||||||
|
textViewPath = view.findViewById(R.id.textViewPath);
|
||||||
|
textViewResolutionHeight = view.findViewById(R.id.textViewResHeight);
|
||||||
|
textViewResolutionWidth = view.findViewById(R.id.textViewResWidth);
|
||||||
|
imageView = view.findViewById(R.id.imageViewResult);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
package one.nem.lacerta.component.scanner;
|
||||||
|
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
|
||||||
|
public class CapturedData {
|
||||||
|
|
||||||
|
private String path;
|
||||||
|
private String resolutionHeight;
|
||||||
|
private String resolutionWidth;
|
||||||
|
private String size;
|
||||||
|
private Bitmap bitmap;
|
||||||
|
|
||||||
|
// Constructor
|
||||||
|
|
||||||
|
public CapturedData(String path, String resolutionHeight, String resolutionWidth, String size, Bitmap bitmap) {
|
||||||
|
this.path = path;
|
||||||
|
this.resolutionHeight = resolutionHeight;
|
||||||
|
this.resolutionWidth = resolutionWidth;
|
||||||
|
this.size = size;
|
||||||
|
this.bitmap = bitmap;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Getters
|
||||||
|
|
||||||
|
public String getPath() {
|
||||||
|
return path;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getResolutionHeight() {
|
||||||
|
return resolutionHeight;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getResolutionWidth() {
|
||||||
|
return resolutionWidth;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSize() {
|
||||||
|
return size;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Bitmap getBitmap() {
|
||||||
|
return bitmap;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,144 @@
|
|||||||
|
package one.nem.lacerta.component.scanner;
|
||||||
|
|
||||||
|
import android.app.Activity;
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
import android.net.Uri;
|
||||||
|
import android.os.Bundle;
|
||||||
|
|
||||||
|
import androidx.activity.result.ActivityResultLauncher;
|
||||||
|
import androidx.activity.result.contract.ActivityResultContracts;
|
||||||
|
import androidx.core.content.FileProvider;
|
||||||
|
import androidx.fragment.app.Fragment;
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
|
import android.os.Environment;
|
||||||
|
import android.provider.MediaStore;
|
||||||
|
import android.util.Log;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.TextView;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import java.io.File;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.Locale;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A simple {@link Fragment} subclass.
|
||||||
|
* Use the {@link ScannerDataManagerStubFragment#newInstance} factory method to
|
||||||
|
* create an instance of this fragment.
|
||||||
|
*/
|
||||||
|
public class ScannerDataManagerStubFragment extends Fragment {
|
||||||
|
|
||||||
|
// TODO-rca: 時間があったらcacheを使うようにする?
|
||||||
|
|
||||||
|
// Results
|
||||||
|
private ArrayList<CapturedData> results = new ArrayList<>();
|
||||||
|
|
||||||
|
private Uri photoURI;
|
||||||
|
|
||||||
|
private final ActivityResultLauncher<Intent> cameraLauncher = registerForActivityResult(
|
||||||
|
new ActivityResultContracts.StartActivityForResult(),
|
||||||
|
result -> {
|
||||||
|
if (result.getResultCode() == Activity.RESULT_OK) {
|
||||||
|
try {
|
||||||
|
if (getActivity() == null) {
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "getActivity() is null");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (photoURI == null) {
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "photoURI is null");
|
||||||
|
Toast.makeText(getActivity(), "photoURI is null", Toast.LENGTH_LONG).show();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
Bitmap imageBitmap = MediaStore.Images.Media.getBitmap(getActivity().getContentResolver(), photoURI);
|
||||||
|
results.add(new CapturedData("Placeholder", Integer.toString(imageBitmap.getHeight()), Integer.toString(imageBitmap.getWidth()), "Placeholder", imageBitmap));
|
||||||
|
} catch (IOException e) {
|
||||||
|
Log.e("ScannerDataManagerStubFragment", "Error occurred while reading the file", e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
public ScannerDataManagerStubFragment() {
|
||||||
|
// Required empty public constructor
|
||||||
|
}
|
||||||
|
// TODO: Rename and change types and number of parameters
|
||||||
|
public static ScannerDataManagerStubFragment newInstance() {
|
||||||
|
ScannerDataManagerStubFragment fragment = new ScannerDataManagerStubFragment();
|
||||||
|
Bundle args = new Bundle();
|
||||||
|
fragment.setArguments(args);
|
||||||
|
return fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||||
|
Bundle savedInstanceState) {
|
||||||
|
// Inflate the layout for this fragment
|
||||||
|
return inflater.inflate(R.layout.fragment_scanner_data_manager_stub, container, false);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onViewCreated(View view, Bundle savedInstanceState) {
|
||||||
|
super.onViewCreated(view, savedInstanceState);
|
||||||
|
|
||||||
|
view.findViewById(R.id.button_call_camera).setOnClickListener(v -> {
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "button_call_camera clicked");
|
||||||
|
Intent takePictureIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
|
||||||
|
if (takePictureIntent.resolveActivity(getActivity().getPackageManager()) != null) {
|
||||||
|
File photoFile = null;
|
||||||
|
try {
|
||||||
|
String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss", Locale.US).format(new Date());
|
||||||
|
String imageFileName = "JPEG_" + timeStamp + "_";
|
||||||
|
File storageDir = getActivity().getExternalFilesDir(Environment.DIRECTORY_PICTURES);
|
||||||
|
photoFile = File.createTempFile(imageFileName, ".jpg", storageDir);
|
||||||
|
} catch (IOException ex) {
|
||||||
|
Log.e("ScannerDataManagerStubFragment", "Error occurred while creating the file", ex);
|
||||||
|
}
|
||||||
|
if (photoFile != null) {
|
||||||
|
photoURI = FileProvider.getUriForFile(getActivity(), "one.nem.lacerta.provider", photoFile);
|
||||||
|
takePictureIntent.putExtra(MediaStore.EXTRA_OUTPUT, photoURI);
|
||||||
|
cameraLauncher.launch(takePictureIntent);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "photoFile is null");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "camera not available");
|
||||||
|
}
|
||||||
|
updateResults();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onResume() {
|
||||||
|
super.onResume();
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "onResume");
|
||||||
|
updateResults();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void updateResults() {
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "updateResults");
|
||||||
|
|
||||||
|
// TODO-rca: エラーハンドリング
|
||||||
|
RecyclerView recyclerView = getView().findViewById(R.id.result_recycler_view);
|
||||||
|
|
||||||
|
recyclerView.setLayoutManager(new androidx.recyclerview.widget.LinearLayoutManager(getContext()));
|
||||||
|
recyclerView.setAdapter(new CaptureResultAdapter(this.results));
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:theme="@style/Theme.Lacerta"
|
||||||
|
tools:context=".ScannerDataManagerStubFragment" >
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/action_button_container"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
|
|
||||||
|
<com.google.android.material.button.MaterialButton
|
||||||
|
android:id="@+id/button_call_camera"
|
||||||
|
style="@style/Widget.Material3.Button.IconButton.Filled"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="16px"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="Call camera" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/result_recycler_view"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/action_button_container" />
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="24px">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/imageViewResult"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
tools:srcCompat="@android:drawable/presence_video_online"
|
||||||
|
android:adjustViewBounds="true"/>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/imageViewResult">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="2"
|
||||||
|
android:text="Resolution:"
|
||||||
|
android:textIsSelectable="false"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/textViewResHeight"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="Height"
|
||||||
|
android:textIsSelectable="false"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/textViewResWidth"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="Width"
|
||||||
|
android:textIsSelectable="false"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/textViewPath"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="Path"
|
||||||
|
android:textIsSelectable="false"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<resources>
|
||||||
|
<!-- TODO: Remove or change this placeholder text -->
|
||||||
|
<string name="hello_blank_fragment">Hello blank fragment</string>
|
||||||
|
</resources>
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package one.nem.lacerta.component.scanner;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example local unit test, which will execute on the development machine (host).
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
public class ExampleUnitTest {
|
||||||
|
@Test
|
||||||
|
public void addition_isCorrect() {
|
||||||
|
assertEquals(4, 2 + 2);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
/build
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
plugins {
|
||||||
|
alias(libs.plugins.com.android.library)
|
||||||
|
}
|
||||||
|
|
||||||
|
android {
|
||||||
|
namespace 'one.nem.lacerta.component.viewer'
|
||||||
|
compileSdk 33
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
minSdk 26
|
||||||
|
|
||||||
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
consumerProguardFiles "consumer-rules.pro"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
|
||||||
|
implementation libs.androidx.appcompat
|
||||||
|
implementation libs.com.google.android.material
|
||||||
|
testImplementation libs.junit
|
||||||
|
androidTestImplementation libs.androidx.test.ext.junit
|
||||||
|
androidTestImplementation libs.androidx.test.espresso.core
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package one.nem.lacerta.component.viewer;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import androidx.test.platform.app.InstrumentationRegistry;
|
||||||
|
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||||
|
assertEquals("one.nem.lacerta.component.viewer.test", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
</manifest>
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package one.nem.lacerta.component.viewer;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example local unit test, which will execute on the development machine (host).
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
public class ExampleUnitTest {
|
||||||
|
@Test
|
||||||
|
public void addition_isCorrect() {
|
||||||
|
assertEquals(4, 2 + 2);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
/build
|
||||||
@@ -0,0 +1,56 @@
|
|||||||
|
plugins {
|
||||||
|
alias(libs.plugins.com.android.library)
|
||||||
|
id 'com.google.dagger.hilt.android'
|
||||||
|
}
|
||||||
|
|
||||||
|
android {
|
||||||
|
namespace 'one.nem.lacerta.data'
|
||||||
|
compileSdk 34
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
minSdk 26
|
||||||
|
|
||||||
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
consumerProguardFiles "consumer-rules.pro"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
|
||||||
|
implementation libs.androidx.appcompat
|
||||||
|
implementation libs.com.google.android.material
|
||||||
|
testImplementation libs.junit
|
||||||
|
androidTestImplementation libs.androidx.test.ext.junit
|
||||||
|
androidTestImplementation libs.androidx.test.espresso.core
|
||||||
|
|
||||||
|
// Hilt (DI)
|
||||||
|
implementation libs.com.google.dagger.hilt.android
|
||||||
|
annotationProcessor libs.com.google.dagger.hilt.compiler
|
||||||
|
|
||||||
|
// JGit
|
||||||
|
implementation 'org.eclipse.jgit:org.eclipse.jgit:6.8.0.202311291450-r'
|
||||||
|
|
||||||
|
// Room
|
||||||
|
implementation libs.androidx.room.runtime
|
||||||
|
annotationProcessor libs.androidx.room.compiler
|
||||||
|
|
||||||
|
// Utilsモジュール
|
||||||
|
implementation project(':utils')
|
||||||
|
|
||||||
|
// 型モジュール
|
||||||
|
implementation project(':model')
|
||||||
|
|
||||||
|
// データソースモジュール
|
||||||
|
implementation project(':source')
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package one.nem.lacerta.data;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import androidx.test.platform.app.InstrumentationRegistry;
|
||||||
|
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||||
|
assertEquals("one.nem.lacerta.data.test", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
</manifest>
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
package one.nem.lacerta.data;
|
||||||
|
|
||||||
|
import java.lang.reflect.Array;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
import one.nem.lacerta.model.document.DocumentMeta;
|
||||||
|
import one.nem.lacerta.model.document.DocumentDetail;
|
||||||
|
import one.nem.lacerta.model.document.path.DocumentPath;
|
||||||
|
import one.nem.lacerta.model.document.tag.DocumentTag;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ドキュメントのデータを取得する
|
||||||
|
*/
|
||||||
|
public interface Document {
|
||||||
|
|
||||||
|
ArrayList<DocumentMeta> getAllDocumentMetas(int limit);
|
||||||
|
|
||||||
|
ArrayList<DocumentMeta> getAllDocumentMetas(int limit, int offset);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新の新しいドキュメントから順に並べてlimit件取得する
|
||||||
|
* @param limit 取得する上限数
|
||||||
|
*/
|
||||||
|
ArrayList<DocumentMeta> getRecentDocumentMetas(int limit);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新の新しいドキュメントから順に並べてoffset位置からlimit件取得する
|
||||||
|
* @param limit 取得する上限数
|
||||||
|
* @param offset 取得するオフセット
|
||||||
|
*/
|
||||||
|
ArrayList<DocumentMeta> getRecentDocumentMetas(int limit, int offset);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ドキュメントIDからDocumentDetailを取得する
|
||||||
|
* @param id ドキュメントID
|
||||||
|
*/
|
||||||
|
DocumentDetail getDocumentDetail(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* DocumentMetaからDocumentDetailを取得する
|
||||||
|
* @param meta DocumentMeta
|
||||||
|
*/
|
||||||
|
DocumentDetail getDocumentDetailByMeta(DocumentMeta meta); // 簡単に使えるように
|
||||||
|
|
||||||
|
DocumentDetail createDocumentByMeta(DocumentMeta meta);
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
package one.nem.lacerta.data;
|
||||||
|
|
||||||
|
import one.nem.lacerta.model.document.DocumentMeta;
|
||||||
|
import one.nem.lacerta.model.document.DocumentDetail;
|
||||||
|
import one.nem.lacerta.model.document.path.DocumentPath;
|
||||||
|
import one.nem.lacerta.model.document.tag.DocumentTag;
|
||||||
|
|
||||||
|
public interface DocumentDebug {
|
||||||
|
|
||||||
|
void insertDocument(DocumentMeta meta, DocumentDetail detail);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package one.nem.lacerta.data.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import javax.inject.Inject;
|
||||||
|
|
||||||
|
import one.nem.lacerta.data.DocumentDebug;
|
||||||
|
import one.nem.lacerta.model.document.DocumentDetail;
|
||||||
|
import one.nem.lacerta.model.document.DocumentMeta;
|
||||||
|
|
||||||
|
import one.nem.lacerta.source.database.entity.DocumentEntity;
|
||||||
|
import one.nem.lacerta.source.database.entity.LibraryEntity;
|
||||||
|
import one.nem.lacerta.source.database.entity.TagEntity;
|
||||||
|
|
||||||
|
import one.nem.lacerta.source.database.LacertaDatabase;
|
||||||
|
|
||||||
|
public class DocumentDebugImpl implements DocumentDebug{
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
LacertaDatabase database;
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
public DocumentDebugImpl() {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void insertDocument(DocumentMeta meta, DocumentDetail detail) {
|
||||||
|
DocumentEntity documentEntity = new DocumentEntity();
|
||||||
|
LibraryEntity libraryEntity = new LibraryEntity();
|
||||||
|
|
||||||
|
documentEntity.id = meta.getId();
|
||||||
|
documentEntity.title = meta.getTitle();
|
||||||
|
documentEntity.createdAt = meta.getCreatedAt();
|
||||||
|
documentEntity.updatedAt = meta.getUpdatedAt();
|
||||||
|
documentEntity.author = detail.getAuthor();
|
||||||
|
documentEntity.defaultBranch = detail.getDefaultBranch();
|
||||||
|
// ArrayListからListに変換
|
||||||
|
documentEntity.tagIds = meta.getTagIds();
|
||||||
|
|
||||||
|
libraryEntity.id = meta.getId();
|
||||||
|
libraryEntity.path = "Placeholder";
|
||||||
|
libraryEntity.rootPath = "Placeholder";
|
||||||
|
|
||||||
|
database.documentDao().insert(documentEntity);
|
||||||
|
database.libraryDao().insert(libraryEntity);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,141 @@
|
|||||||
|
package one.nem.lacerta.data.impl;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import javax.inject.Inject;
|
||||||
|
|
||||||
|
import one.nem.lacerta.data.Document;
|
||||||
|
|
||||||
|
import one.nem.lacerta.model.document.DocumentMeta;
|
||||||
|
import one.nem.lacerta.model.document.DocumentDetail;
|
||||||
|
|
||||||
|
import one.nem.lacerta.model.document.path.DocumentPath;
|
||||||
|
import one.nem.lacerta.model.document.tag.DocumentTag;
|
||||||
|
import one.nem.lacerta.source.database.LacertaDatabase;
|
||||||
|
|
||||||
|
import one.nem.lacerta.source.database.entity.DocumentEntity;
|
||||||
|
import one.nem.lacerta.source.database.entity.LibraryEntity;
|
||||||
|
import one.nem.lacerta.source.database.entity.TagEntity;
|
||||||
|
|
||||||
|
import one.nem.lacerta.source.jgit.JGitRepository;
|
||||||
|
import one.nem.lacerta.utils.repository.DeviceInfoUtils;
|
||||||
|
|
||||||
|
|
||||||
|
public class DocumentImpl implements Document{
|
||||||
|
|
||||||
|
private LacertaDatabase database;
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
public DocumentImpl(LacertaDatabase database) {
|
||||||
|
this.database = database;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
JGitRepository jGitRepository;
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
DeviceInfoUtils deviceInfoUtils;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ArrayList<DocumentMeta> getAllDocumentMetas(int limit) {
|
||||||
|
ArrayList<DocumentMeta> documentMetas = new ArrayList<>();
|
||||||
|
List<DocumentEntity> documentEntities = database.documentDao().getAllWithLimit(limit);
|
||||||
|
|
||||||
|
for (DocumentEntity documentEntity : documentEntities) {
|
||||||
|
// タグ取得
|
||||||
|
// TODO-rca: 切り出すべきかも?
|
||||||
|
List<TagEntity> tagEntities = database.tagDao().findByIds(documentEntity.tagIds);
|
||||||
|
ArrayList<DocumentTag> documentTags = new ArrayList<>();
|
||||||
|
for (TagEntity tagEntity : tagEntities) {
|
||||||
|
documentTags.add(new DocumentTag(tagEntity.id, tagEntity.tagName, tagEntity.color));
|
||||||
|
}
|
||||||
|
|
||||||
|
// 組み立て処理
|
||||||
|
// 可読性が終わるのでコンストラクタはつかわないほうがいいかも?
|
||||||
|
DocumentMeta documentMeta = new DocumentMeta();
|
||||||
|
documentMeta.setId(documentEntity.id);
|
||||||
|
documentMeta.setTitle(documentEntity.title);
|
||||||
|
documentMeta.setCreatedAt(documentEntity.createdAt);
|
||||||
|
documentMeta.setUpdatedAt(documentEntity.updatedAt);
|
||||||
|
documentMeta.setTags(documentTags);
|
||||||
|
|
||||||
|
documentMetas.add(documentMeta);
|
||||||
|
}
|
||||||
|
|
||||||
|
return documentMetas;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ArrayList<DocumentMeta> getAllDocumentMetas(int limit, int offset) {
|
||||||
|
return null; // TODO-rca: 実装する
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ArrayList<DocumentMeta> getRecentDocumentMetas(int limit) {
|
||||||
|
// ArrayList<DocumentMeta> documentMetas = new ArrayList<>();
|
||||||
|
// database.documentDao().
|
||||||
|
// TODO-rca: 履歴取得するDao実装する
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ArrayList<DocumentMeta> getRecentDocumentMetas(int limit, int offset) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public DocumentDetail getDocumentDetail(String id) {
|
||||||
|
DocumentDetail documentDetail = new DocumentDetail();
|
||||||
|
DocumentEntity documentEntity = database.documentDao().findById(id);
|
||||||
|
|
||||||
|
// タグ取得
|
||||||
|
// TODO-rca: 切り出すべきかも?
|
||||||
|
List<TagEntity> tagEntities = database.tagDao().findByIds(documentEntity.tagIds);
|
||||||
|
ArrayList<DocumentTag> documentTags = new ArrayList<>();
|
||||||
|
for (TagEntity tagEntity : tagEntities) {
|
||||||
|
documentTags.add(new DocumentTag(tagEntity.id, tagEntity.tagName, tagEntity.color));
|
||||||
|
}
|
||||||
|
|
||||||
|
// パス取得
|
||||||
|
// TODO-rca: 切り出すべきかも?
|
||||||
|
LibraryEntity libraryEntity = database.libraryDao().findById(id);
|
||||||
|
DocumentPath documentPath = new DocumentPath(libraryEntity.rootPath, libraryEntity.path);
|
||||||
|
|
||||||
|
// リポジトリ取得
|
||||||
|
documentDetail.setRepository(jGitRepository.getRepository(id)); // TODO-rca: エラーハンドリング
|
||||||
|
|
||||||
|
// 組み立て処理
|
||||||
|
// 可読性が終わるのでコンストラクタはつかわないほうがいいかも?
|
||||||
|
DocumentMeta documentMeta = new DocumentMeta();
|
||||||
|
documentMeta.setId(documentEntity.id);
|
||||||
|
documentMeta.setTitle(documentEntity.title);
|
||||||
|
documentMeta.setCreatedAt(documentEntity.createdAt);
|
||||||
|
documentMeta.setUpdatedAt(documentEntity.updatedAt);
|
||||||
|
documentMeta.setTags(documentTags);
|
||||||
|
|
||||||
|
documentDetail.setMeta(documentMeta);
|
||||||
|
documentDetail.setAuthor(documentEntity.author);
|
||||||
|
documentDetail.setPath(documentPath);
|
||||||
|
documentDetail.setDefaultBranch(documentEntity.defaultBranch);
|
||||||
|
|
||||||
|
return documentDetail;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public DocumentDetail getDocumentDetailByMeta(DocumentMeta meta) {
|
||||||
|
return getDocumentDetail(meta.getId()); // TODO-rca: 効率悪いのでMetaはもらった物を使うようにする(処理を切り分ける?)
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public DocumentDetail createDocumentByMeta(DocumentMeta meta) {
|
||||||
|
DocumentDetail documentDetail = new DocumentDetail();
|
||||||
|
|
||||||
|
documentDetail.setMeta(meta);
|
||||||
|
documentDetail.setAuthor("author"); // TODO-rca: SharedPrefを扱う機能を作ってそこから取得するようにする or Gitの設定を参照するようにする
|
||||||
|
documentDetail.setPath(new DocumentPath(deviceInfoUtils.getExternalStorageDirectoryString(), meta.getId()));
|
||||||
|
documentDetail.setDefaultBranch("master"); // TODO-rca: SharedPrefを扱う機能を作ってそこから取得するようにする?
|
||||||
|
|
||||||
|
return documentDetail;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package one.nem.lacerta.data.module;
|
||||||
|
|
||||||
|
import dagger.Binds;
|
||||||
|
import dagger.Module;
|
||||||
|
import dagger.hilt.InstallIn;
|
||||||
|
import dagger.hilt.components.SingletonComponent;
|
||||||
|
import one.nem.lacerta.data.DocumentDebug;
|
||||||
|
import one.nem.lacerta.data.impl.DocumentDebugImpl;
|
||||||
|
|
||||||
|
@Module
|
||||||
|
@InstallIn(SingletonComponent.class) // TODO-rca: Singletonでいいのか検討する
|
||||||
|
abstract public class DocumentDebugModule {
|
||||||
|
|
||||||
|
@Binds
|
||||||
|
public abstract DocumentDebug bindDocumentDebug(DocumentDebugImpl documentDebugImpl);
|
||||||
|
}
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package one.nem.lacerta.data.module;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import dagger.Binds;
|
||||||
|
import dagger.Module;
|
||||||
|
import dagger.hilt.InstallIn;
|
||||||
|
import dagger.hilt.components.SingletonComponent;
|
||||||
|
|
||||||
|
import one.nem.lacerta.data.Document;
|
||||||
|
import one.nem.lacerta.data.impl.DocumentImpl;
|
||||||
|
|
||||||
|
@Module
|
||||||
|
@InstallIn(SingletonComponent.class) // TODO-rca: Singletonであるべきか考える
|
||||||
|
abstract public class DocumentModule {
|
||||||
|
|
||||||
|
@Binds
|
||||||
|
public abstract Document bindDocument(DocumentImpl documentImpl);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
package one.nem.lacerta.data.processor;
|
||||||
|
|
||||||
|
import org.eclipse.jgit.lib.Repository;
|
||||||
|
|
||||||
|
import one.nem.lacerta.model.document.DocumentDetail;
|
||||||
|
|
||||||
|
public interface DocumentProcessor {
|
||||||
|
// TODO-rca: Initをここでやるべきか検討する?, Documentモデルを作るべきか検討する?
|
||||||
|
|
||||||
|
void setDocumentDetail(DocumentDetail documentDetail);
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
package one.nem.lacerta.data.processor.impl;
|
||||||
|
|
||||||
|
public class DocumentProcessorImpl {
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package one.nem.lacerta.data;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example local unit test, which will execute on the development machine (host).
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
public class ExampleUnitTest {
|
||||||
|
@Test
|
||||||
|
public void addition_isCorrect() {
|
||||||
|
assertEquals(4, 2 + 2);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
/build
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
plugins {
|
||||||
|
alias(libs.plugins.com.android.library)
|
||||||
|
}
|
||||||
|
|
||||||
|
android {
|
||||||
|
namespace 'one.nem.lacerta.feature.common'
|
||||||
|
compileSdk 33
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
minSdk 26
|
||||||
|
|
||||||
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
consumerProguardFiles "consumer-rules.pro"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
|
||||||
|
implementation libs.androidx.appcompat
|
||||||
|
implementation libs.com.google.android.material
|
||||||
|
testImplementation libs.junit
|
||||||
|
androidTestImplementation libs.androidx.test.ext.junit
|
||||||
|
androidTestImplementation libs.androidx.test.espresso.core
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package one.nem.lacerta.feature.common;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import androidx.test.platform.app.InstrumentationRegistry;
|
||||||
|
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||||
|
assertEquals("one.nem.lacerta.feature.common.test", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
</manifest>
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package one.nem.lacerta.feature.common;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example local unit test, which will execute on the development machine (host).
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
public class ExampleUnitTest {
|
||||||
|
@Test
|
||||||
|
public void addition_isCorrect() {
|
||||||
|
assertEquals(4, 2 + 2);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
/build
|
||||||
@@ -0,0 +1,68 @@
|
|||||||
|
plugins {
|
||||||
|
alias(libs.plugins.com.android.library)
|
||||||
|
id 'com.google.dagger.hilt.android'
|
||||||
|
}
|
||||||
|
|
||||||
|
android {
|
||||||
|
namespace 'one.nem.lacerta.feature.debug'
|
||||||
|
compileSdk 34
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
minSdk 26
|
||||||
|
|
||||||
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
consumerProguardFiles "consumer-rules.pro"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility JavaVersion.VERSION_1_8
|
||||||
|
targetCompatibility JavaVersion.VERSION_1_8
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
|
||||||
|
implementation libs.androidx.appcompat
|
||||||
|
implementation libs.com.google.android.material
|
||||||
|
implementation libs.androidx.activity
|
||||||
|
implementation libs.androidx.constraintlayout
|
||||||
|
testImplementation libs.junit
|
||||||
|
androidTestImplementation libs.androidx.test.ext.junit
|
||||||
|
androidTestImplementation libs.androidx.test.espresso.core
|
||||||
|
|
||||||
|
// Navigation
|
||||||
|
implementation libs.navigation.fragment
|
||||||
|
implementation libs.navigation.ui
|
||||||
|
implementation libs.navigation.dynamic.features.fragment
|
||||||
|
|
||||||
|
// Hilt (DI)
|
||||||
|
implementation libs.com.google.dagger.hilt.android
|
||||||
|
annotationProcessor libs.com.google.dagger.hilt.compiler
|
||||||
|
|
||||||
|
// JGit
|
||||||
|
implementation 'org.eclipse.jgit:org.eclipse.jgit:6.8.0.202311291450-r'
|
||||||
|
|
||||||
|
// 内部モジュール
|
||||||
|
// data
|
||||||
|
implementation project(':data')
|
||||||
|
|
||||||
|
// Debug
|
||||||
|
implementation project(':source')
|
||||||
|
implementation project(':utils')
|
||||||
|
|
||||||
|
// 型
|
||||||
|
implementation project(':model')
|
||||||
|
|
||||||
|
// Shared
|
||||||
|
implementation project(':shared:ui')
|
||||||
|
|
||||||
|
// Scanner
|
||||||
|
implementation project(':component:scanner')
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package one.nem.lacerta.feature.debug;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
|
||||||
|
import androidx.test.platform.app.InstrumentationRegistry;
|
||||||
|
import androidx.test.ext.junit.runners.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
|
||||||
|
assertEquals("one.nem.lacerta.feature.debug.test", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
<application>
|
||||||
|
<activity
|
||||||
|
android:name=".DebugMenuContainerActivity"
|
||||||
|
android:exported="false" />
|
||||||
|
</application>
|
||||||
|
|
||||||
|
</manifest>
|
||||||
@@ -0,0 +1,67 @@
|
|||||||
|
package one.nem.lacerta.feature.debug;
|
||||||
|
|
||||||
|
import android.os.Bundle;
|
||||||
|
|
||||||
|
import androidx.fragment.app.Fragment;
|
||||||
|
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
import dagger.hilt.android.AndroidEntryPoint;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A simple {@link Fragment} subclass.
|
||||||
|
* Use the {@link DebugMenuContainerFragment#newInstance} factory method to
|
||||||
|
* create an instance of this fragment.
|
||||||
|
*/
|
||||||
|
@AndroidEntryPoint
|
||||||
|
public class DebugMenuContainerFragment extends Fragment {
|
||||||
|
|
||||||
|
// TODO: Rename parameter arguments, choose names that match
|
||||||
|
// the fragment initialization parameters, e.g. ARG_ITEM_NUMBER
|
||||||
|
private static final String ARG_PARAM1 = "param1";
|
||||||
|
private static final String ARG_PARAM2 = "param2";
|
||||||
|
|
||||||
|
// TODO: Rename and change types of parameters
|
||||||
|
private String mParam1;
|
||||||
|
private String mParam2;
|
||||||
|
|
||||||
|
public DebugMenuContainerFragment() {
|
||||||
|
// Required empty public constructor
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Use this factory method to create a new instance of
|
||||||
|
* this fragment using the provided parameters.
|
||||||
|
*
|
||||||
|
* @param param1 Parameter 1.
|
||||||
|
* @param param2 Parameter 2.
|
||||||
|
* @return A new instance of fragment DebugMenuSubContainerFragment.
|
||||||
|
*/
|
||||||
|
// TODO: Rename and change types and number of parameters
|
||||||
|
public static DebugMenuContainerFragment newInstance(String param1, String param2) {
|
||||||
|
DebugMenuContainerFragment fragment = new DebugMenuContainerFragment();
|
||||||
|
Bundle args = new Bundle();
|
||||||
|
args.putString(ARG_PARAM1, param1);
|
||||||
|
args.putString(ARG_PARAM2, param2);
|
||||||
|
fragment.setArguments(args);
|
||||||
|
return fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
if (getArguments() != null) {
|
||||||
|
mParam1 = getArguments().getString(ARG_PARAM1);
|
||||||
|
mParam2 = getArguments().getString(ARG_PARAM2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||||
|
Bundle savedInstanceState) {
|
||||||
|
// Inflate the layout for this fragment
|
||||||
|
return inflater.inflate(R.layout.fragment_debug_menu_container, container, false);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,81 @@
|
|||||||
|
package one.nem.lacerta.feature.debug;
|
||||||
|
|
||||||
|
import android.os.Bundle;
|
||||||
|
|
||||||
|
import androidx.fragment.app.Fragment;
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import javax.inject.Inject;
|
||||||
|
|
||||||
|
import dagger.hilt.android.AndroidEntryPoint;
|
||||||
|
import one.nem.lacerta.data.Document;
|
||||||
|
import one.nem.lacerta.feature.debug.common.adapter.DebugMenuDocumentListItemAdapter;
|
||||||
|
import one.nem.lacerta.feature.debug.common.model.DebugMenuDocumentListItem;
|
||||||
|
import one.nem.lacerta.model.document.DocumentMeta;
|
||||||
|
import one.nem.lacerta.utils.LacertaLogger;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A simple {@link Fragment} subclass.
|
||||||
|
* Use the {@link DebugMenuDocumentTesterListFragment#newInstance} factory method to
|
||||||
|
* create an instance of this fragment.
|
||||||
|
*/
|
||||||
|
|
||||||
|
@AndroidEntryPoint
|
||||||
|
public class DebugMenuDocumentTesterListFragment extends Fragment {
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
Document document;
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
LacertaLogger logger;
|
||||||
|
|
||||||
|
public DebugMenuDocumentTesterListFragment() {
|
||||||
|
// Required empty public constructor
|
||||||
|
}
|
||||||
|
|
||||||
|
public static DebugMenuDocumentTesterListFragment newInstance() {
|
||||||
|
DebugMenuDocumentTesterListFragment fragment = new DebugMenuDocumentTesterListFragment();
|
||||||
|
Bundle args = new Bundle();
|
||||||
|
fragment.setArguments(args);
|
||||||
|
return fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||||
|
Bundle savedInstanceState) {
|
||||||
|
// Inflate the layout for this fragment
|
||||||
|
View view = inflater.inflate(R.layout.fragment_debug_menu_document_tester_list, container, false);
|
||||||
|
|
||||||
|
RecyclerView recyclerView = view.findViewById(R.id.recycler_view_document_list);
|
||||||
|
recyclerView.setLayoutManager(new androidx.recyclerview.widget.LinearLayoutManager(getContext()));
|
||||||
|
|
||||||
|
ArrayList<DocumentMeta> documentMetas = document.getAllDocumentMetas(100);
|
||||||
|
|
||||||
|
logger.debug("Debug/DocList", "Document count: " + documentMetas.size());
|
||||||
|
|
||||||
|
List<DebugMenuDocumentListItem> debugMenuDocumentListItems = new ArrayList<>();
|
||||||
|
|
||||||
|
for (DocumentMeta documentMeta : documentMetas) {
|
||||||
|
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||||
|
debugMenuDocumentListItems.add(new DebugMenuDocumentListItem(documentMeta.getTitle(), "Internal Id: " + documentMeta.getId(), simpleDateFormat.format(documentMeta.getUpdatedAt())));
|
||||||
|
}
|
||||||
|
|
||||||
|
DebugMenuDocumentListItemAdapter adapter = new DebugMenuDocumentListItemAdapter(debugMenuDocumentListItems);
|
||||||
|
recyclerView.setAdapter(adapter);
|
||||||
|
|
||||||
|
return view;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,72 @@
|
|||||||
|
package one.nem.lacerta.feature.debug;
|
||||||
|
|
||||||
|
import android.os.Bundle;
|
||||||
|
|
||||||
|
import androidx.fragment.app.Fragment;
|
||||||
|
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
import com.google.android.material.textfield.TextInputEditText;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
import javax.inject.Inject;
|
||||||
|
|
||||||
|
import dagger.hilt.android.AndroidEntryPoint;
|
||||||
|
import dagger.multibindings.IntKey;
|
||||||
|
import one.nem.lacerta.data.DocumentDebug;
|
||||||
|
|
||||||
|
import one.nem.lacerta.model.document.DocumentMeta;
|
||||||
|
import one.nem.lacerta.model.document.DocumentDetail;
|
||||||
|
|
||||||
|
import one.nem.lacerta.model.document.path.DocumentPath;
|
||||||
|
import one.nem.lacerta.model.document.tag.DocumentTag;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A simple {@link Fragment} subclass.
|
||||||
|
* Use the {@link DebugMenuDocumentTesterManageFragment#newInstance} factory method to
|
||||||
|
* create an instance of this fragment.
|
||||||
|
*/
|
||||||
|
@AndroidEntryPoint
|
||||||
|
public class DebugMenuDocumentTesterManageFragment extends Fragment {
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
DocumentDebug documentDebug;
|
||||||
|
|
||||||
|
public DebugMenuDocumentTesterManageFragment() {
|
||||||
|
// Required empty public constructor
|
||||||
|
}
|
||||||
|
|
||||||
|
public static DebugMenuDocumentTesterManageFragment newInstance() {
|
||||||
|
DebugMenuDocumentTesterManageFragment fragment = new DebugMenuDocumentTesterManageFragment();
|
||||||
|
Bundle args = new Bundle();
|
||||||
|
fragment.setArguments(args);
|
||||||
|
return fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||||
|
Bundle savedInstanceState) {
|
||||||
|
// Inflate the layout for this fragment
|
||||||
|
View view = inflater.inflate(R.layout.fragment_debug_menu_document_tester_manage, container, false);
|
||||||
|
|
||||||
|
TextInputEditText editTextDocumentTitle = view.findViewById(R.id.edit_text_document_title);
|
||||||
|
view.findViewById(R.id.button_insert_test_data).setOnClickListener( v -> {
|
||||||
|
|
||||||
|
DocumentMeta meta = new DocumentMeta(editTextDocumentTitle != null ? editTextDocumentTitle.getText().toString() : "empty title"); // TODO-rca: Nullable
|
||||||
|
DocumentPath path = new DocumentPath("root", "test_path");
|
||||||
|
DocumentDetail detail = new DocumentDetail(meta, path, "test_author", "test_default_branch");
|
||||||
|
|
||||||
|
documentDebug.insertDocument(meta, detail);
|
||||||
|
});
|
||||||
|
|
||||||
|
return view;
|
||||||
|
}
|
||||||
|
}
|
||||||