Repository navigation
Expand file tree
/
Copy pathtemplate.xml
More file actions
106 lines (90 loc) · 3.14 KB
/
Copy pathtemplate.xml
File metadata and controls
106 lines (90 loc) · 3.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
<?xml version="1.0"?>
<template
name="Create"
description="Creates a new MVP scructure"
format="1"
minApi="15"
minBuildApi="15"
revision="1">
<category value="MVP"/>
<formfactor value="Mobile"/>
<parameter
id="uiComponent"
name="UI Component"
type="enum"
default="activity"
help="Select UI component for create some project base elements." >
<option id="activity">Activity</option>
<option id="fragment">Fragment</option>
<option id="dialog">Dialog Fragment</option>
</parameter>
<parameter
id="structure"
name="Folder Structure"
type="enum"
default="all_in_one"
help="Select Folder Structure." >
<option id="all_in_one">All In One; root -> (presenter; ui; view)</option>
<option id="all_in_one_contract">All In One Contract!!!; root -> (presenter; ui; view)</option>
<option id="separated">Separated; root -> presenter; root -> ui -> (activity|fragment|dialog); root -> view</option>
<option id="separated_contract">Separated Contract!!!; root -> presenter; root -> ui -> (activity|fragment|dialog); root -> view</option>
</parameter>
<parameter
name="Class Name for package"
constraints="nonempty"
id="className"
type="string"/>
<parameter
name="Is Kotlin?"
default="true"
help="If true then was created *.kt files else *.java"
id="isKotlin"
type="boolean"/>
<parameter
name="Generate Layout"
default="true"
help="If true, then in res/layout was created ${layoutName}"
id="isCreateLayout"
type="boolean"/>
<parameter
name="Launcher Activity"
default="false"
help="If true, this activity will have a CATEGORY_LAUNCHER intent filter, making it visible in the launcher"
id="isLauncher"
visibility="uiComponent == 'activity'"
type="boolean"/>
<parameter
name="Portrait Orientation"
default="true"
help="If true, this activity will have a android:screenOrientation='portrait'"
id="isPortrait"
visibility="uiComponent == 'activity'"
type="boolean"/>
<parameter
name="Generate View|Presenter"
default="true"
help="If true, then was created Presenter and View class"
id="isGeneratePresenter"
type="boolean"/>
<parameter
name="Generate View,Presenter public?"
default="false"
help="If true, then was created Presenter and View public class.If false, then was package"
id="isGeneratePresenterPublic"
visibility="structure == 'all_in_one' || structure == 'all_in_one_contract'"
type="boolean"/>
<parameter
name="Include Dagger Component"
default="true"
help="If true, then was created DaggerComponent with module and scope"
id="includeDaggerComponent"
type="boolean"/>
<parameter
name="Package name"
constraints="package"
default="com.mycompany.myapp"
id="packageName"
type="string"/>
<globals file="globals.xml.ftl"/>
<execute file="recipe.xml.ftl"/>
</template>