puppet-strings 2.3.0 → 2.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +102 -4
- data/COMMITTERS.md +17 -17
- data/CONTRIBUTING.md +37 -7
- data/README.md +17 -12
- data/lib/puppet-strings.rb +5 -3
- data/lib/puppet-strings/describe.rb +2 -0
- data/lib/puppet-strings/json.rb +2 -0
- data/lib/puppet-strings/markdown.rb +12 -10
- data/lib/puppet-strings/markdown/base.rb +30 -3
- data/lib/puppet-strings/markdown/data_type.rb +18 -0
- data/lib/puppet-strings/markdown/data_types.rb +3 -1
- data/lib/puppet-strings/markdown/defined_type.rb +2 -0
- data/lib/puppet-strings/markdown/defined_types.rb +3 -1
- data/lib/puppet-strings/markdown/function.rb +9 -7
- data/lib/puppet-strings/markdown/functions.rb +3 -1
- data/lib/puppet-strings/markdown/puppet_class.rb +2 -0
- data/lib/puppet-strings/markdown/puppet_classes.rb +3 -1
- data/lib/puppet-strings/markdown/puppet_plan.rb +2 -0
- data/lib/puppet-strings/markdown/puppet_plans.rb +3 -1
- data/lib/puppet-strings/markdown/puppet_task.rb +2 -0
- data/lib/puppet-strings/markdown/puppet_tasks.rb +3 -1
- data/lib/puppet-strings/markdown/resource_type.rb +21 -2
- data/lib/puppet-strings/markdown/resource_types.rb +3 -1
- data/lib/puppet-strings/markdown/table_of_contents.rb +3 -1
- data/lib/puppet-strings/markdown/templates/classes_and_defines.erb +18 -6
- data/lib/puppet-strings/markdown/templates/data_type.erb +30 -7
- data/lib/puppet-strings/markdown/templates/data_type_function.erb +67 -0
- data/lib/puppet-strings/markdown/templates/function.erb +10 -1
- data/lib/puppet-strings/markdown/templates/puppet_task.erb +1 -1
- data/lib/puppet-strings/markdown/templates/resource_type.erb +35 -13
- data/lib/puppet-strings/markdown/templates/table_of_contents.erb +6 -6
- data/lib/puppet-strings/monkey_patches/display_object_command.rb +2 -0
- data/lib/puppet-strings/tasks.rb +2 -0
- data/lib/puppet-strings/tasks/generate.rb +2 -0
- data/lib/puppet-strings/tasks/gh_pages.rb +3 -0
- data/lib/puppet-strings/version.rb +3 -1
- data/lib/puppet-strings/yard.rb +9 -0
- data/lib/puppet-strings/yard/code_objects.rb +2 -0
- data/lib/puppet-strings/yard/code_objects/base.rb +2 -0
- data/lib/puppet-strings/yard/code_objects/class.rb +4 -2
- data/lib/puppet-strings/yard/code_objects/data_type.rb +30 -8
- data/lib/puppet-strings/yard/code_objects/data_type_alias.rb +2 -0
- data/lib/puppet-strings/yard/code_objects/defined_type.rb +4 -2
- data/lib/puppet-strings/yard/code_objects/function.rb +8 -5
- data/lib/puppet-strings/yard/code_objects/group.rb +3 -0
- data/lib/puppet-strings/yard/code_objects/plan.rb +4 -2
- data/lib/puppet-strings/yard/code_objects/provider.rb +6 -0
- data/lib/puppet-strings/yard/code_objects/task.rb +3 -1
- data/lib/puppet-strings/yard/code_objects/type.rb +49 -5
- data/lib/puppet-strings/yard/handlers.rb +2 -0
- data/lib/puppet-strings/yard/handlers/helpers.rb +2 -0
- data/lib/puppet-strings/yard/handlers/json/base.rb +2 -0
- data/lib/puppet-strings/yard/handlers/json/task_handler.rb +2 -0
- data/lib/puppet-strings/yard/handlers/puppet/base.rb +3 -0
- data/lib/puppet-strings/yard/handlers/puppet/class_handler.rb +2 -0
- data/lib/puppet-strings/yard/handlers/puppet/data_type_alias_handler.rb +2 -0
- data/lib/puppet-strings/yard/handlers/puppet/defined_type_handler.rb +2 -0
- data/lib/puppet-strings/yard/handlers/puppet/function_handler.rb +3 -1
- data/lib/puppet-strings/yard/handlers/puppet/plan_handler.rb +2 -0
- data/lib/puppet-strings/yard/handlers/ruby/base.rb +5 -0
- data/lib/puppet-strings/yard/handlers/ruby/data_type_handler.rb +225 -52
- data/lib/puppet-strings/yard/handlers/ruby/function_handler.rb +9 -7
- data/lib/puppet-strings/yard/handlers/ruby/provider_handler.rb +13 -0
- data/lib/puppet-strings/yard/handlers/ruby/rsapi_handler.rb +4 -1
- data/lib/puppet-strings/yard/handlers/ruby/type_base.rb +20 -6
- data/lib/puppet-strings/yard/handlers/ruby/type_extras_handler.rb +6 -3
- data/lib/puppet-strings/yard/handlers/ruby/type_handler.rb +18 -1
- data/lib/puppet-strings/yard/parsers.rb +2 -0
- data/lib/puppet-strings/yard/parsers/json/parser.rb +2 -0
- data/lib/puppet-strings/yard/parsers/json/task_statement.rb +2 -0
- data/lib/puppet-strings/yard/parsers/puppet/parser.rb +18 -14
- data/lib/puppet-strings/yard/parsers/puppet/statement.rb +4 -0
- data/lib/puppet-strings/yard/tags.rb +4 -0
- data/lib/puppet-strings/yard/tags/enum_tag.rb +14 -0
- data/lib/puppet-strings/yard/tags/factory.rb +18 -0
- data/lib/puppet-strings/yard/tags/overload_tag.rb +4 -1
- data/lib/puppet-strings/yard/tags/parameter_directive.rb +5 -4
- data/lib/puppet-strings/yard/tags/property_directive.rb +5 -4
- data/lib/puppet-strings/yard/tags/summary_tag.rb +2 -0
- data/lib/puppet-strings/yard/templates/default/puppet_data_type/html/method_details_list.erb +6 -0
- data/lib/puppet-strings/yard/templates/default/puppet_data_type/html/setup.rb +9 -1
- data/lib/puppet-strings/yard/templates/default/puppet_function/html/setup.rb +1 -1
- data/lib/puppet-strings/yard/templates/default/puppet_type/html/setup.rb +3 -1
- data/lib/puppet-strings/yard/templates/default/tags/html/enum.erb +17 -0
- data/lib/puppet-strings/yard/templates/default/tags/setup.rb +6 -0
- data/lib/puppet-strings/yard/util.rb +7 -4
- data/lib/puppet/application/strings.rb +2 -0
- data/lib/puppet/face/strings.rb +4 -1
- data/lib/puppet/feature/rgen.rb +2 -0
- data/lib/puppet/feature/yard.rb +2 -0
- metadata +14 -51
- data/Gemfile +0 -47
- data/HISTORY.md +0 -218
- data/JSON.md +0 -832
- data/Rakefile +0 -168
- data/codecov.yml +0 -3
- data/misc/ANNOUNCEMENT_TEMPLATE.md +0 -40
- data/spec/acceptance/emit_json_options_spec.rb +0 -69
- data/spec/acceptance/generate_markdown_spec.rb +0 -47
- data/spec/acceptance/running_strings_generate_spec.rb +0 -78
- data/spec/fixtures/acceptance/modules/test/functions/add.pp +0 -9
- data/spec/fixtures/acceptance/modules/test/lib/puppet/functions/4x_function.rb +0 -5
- data/spec/fixtures/acceptance/modules/test/lib/puppet/parser/functions/function3x.rb +0 -2
- data/spec/fixtures/acceptance/modules/test/lib/puppet/provider/server/linux.rb +0 -9
- data/spec/fixtures/acceptance/modules/test/lib/puppet/type/database.rb +0 -15
- data/spec/fixtures/acceptance/modules/test/manifests/init.pp +0 -27
- data/spec/fixtures/acceptance/modules/test/manifests/triple_nested_classes.pp +0 -27
- data/spec/fixtures/acceptance/modules/test/metadata.json +0 -10
- data/spec/fixtures/acceptance/modules/test/types/elephant.pp +0 -2
- data/spec/fixtures/unit/markdown/output.md +0 -508
- data/spec/fixtures/unit/markdown/output_with_data_types.md +0 -553
- data/spec/fixtures/unit/markdown/output_with_plan.md +0 -542
- data/spec/spec_helper.rb +0 -49
- data/spec/spec_helper_acceptance.rb +0 -58
- data/spec/spec_helper_acceptance_local.rb +0 -10
- data/spec/unit/puppet-strings/describe_spec.rb +0 -141
- data/spec/unit/puppet-strings/json_spec.rb +0 -302
- data/spec/unit/puppet-strings/markdown/base_spec.rb +0 -146
- data/spec/unit/puppet-strings/markdown_spec.rb +0 -357
- data/spec/unit/puppet-strings/yard/code_objects/task_spec.rb +0 -92
- data/spec/unit/puppet-strings/yard/handlers/json/task_handler_spec.rb +0 -116
- data/spec/unit/puppet-strings/yard/handlers/puppet/class_handler_spec.rb +0 -217
- data/spec/unit/puppet-strings/yard/handlers/puppet/data_type_alias_handler_spec.rb +0 -65
- data/spec/unit/puppet-strings/yard/handlers/puppet/defined_type_handler_spec.rb +0 -231
- data/spec/unit/puppet-strings/yard/handlers/puppet/function_handler_spec.rb +0 -315
- data/spec/unit/puppet-strings/yard/handlers/ruby/data_type_handler_spec.rb +0 -232
- data/spec/unit/puppet-strings/yard/handlers/ruby/function_handler_spec.rb +0 -746
- data/spec/unit/puppet-strings/yard/handlers/ruby/provider_handler_spec.rb +0 -158
- data/spec/unit/puppet-strings/yard/handlers/ruby/rsapi_handler_spec.rb +0 -235
- data/spec/unit/puppet-strings/yard/handlers/ruby/type_handler_spec.rb +0 -311
- data/spec/unit/puppet-strings/yard/parsers/json/parser_spec.rb +0 -72
- data/spec/unit/puppet-strings/yard/parsers/json/task_statement_spec.rb +0 -56
- data/spec/unit/puppet-strings/yard/parsers/puppet/parser_spec.rb +0 -251
- data/spec/unit/puppet-strings/yard/util_spec.rb +0 -48
@@ -1,542 +0,0 @@
|
|
1
|
-
# Reference
|
2
|
-
<!-- DO NOT EDIT: This document was generated by Puppet Strings -->
|
3
|
-
|
4
|
-
## Table of Contents
|
5
|
-
|
6
|
-
**Classes**
|
7
|
-
|
8
|
-
_Public Classes_
|
9
|
-
|
10
|
-
* [`klass`](#klass): A simple class.
|
11
|
-
|
12
|
-
_Private Classes_
|
13
|
-
|
14
|
-
* `noparams`: Overview for class noparams
|
15
|
-
|
16
|
-
**Defined types**
|
17
|
-
|
18
|
-
* [`klass::dt`](#klassdt): A simple defined type.
|
19
|
-
|
20
|
-
**Resource types**
|
21
|
-
|
22
|
-
* [`apt_key`](#apt_key): Example resource type using the new API.
|
23
|
-
* [`database`](#database): An example database server type.
|
24
|
-
|
25
|
-
**Functions**
|
26
|
-
|
27
|
-
* [`func`](#func): A simple Puppet function.
|
28
|
-
* [`func3x`](#func3x): Documentation for an example 3.x function.
|
29
|
-
* [`func4x`](#func4x): An example 4.x function.
|
30
|
-
* [`func4x_1`](#func4x_1): An example 4.x function with only one signature.
|
31
|
-
|
32
|
-
**Tasks**
|
33
|
-
|
34
|
-
* [`(stdin)`](#(stdin)): Allows you to backup your database to local file.
|
35
|
-
|
36
|
-
**Plans**
|
37
|
-
|
38
|
-
* [`plann`](#plann): A simple plan.
|
39
|
-
|
40
|
-
## Classes
|
41
|
-
|
42
|
-
### klass
|
43
|
-
|
44
|
-
An overview for a simple class.
|
45
|
-
|
46
|
-
* **TODO** Do a thing
|
47
|
-
|
48
|
-
* **Note** some note
|
49
|
-
|
50
|
-
* **Since** 1.0.0
|
51
|
-
|
52
|
-
* **See also**
|
53
|
-
www.puppet.com
|
54
|
-
|
55
|
-
#### Examples
|
56
|
-
|
57
|
-
##### This is an example
|
58
|
-
|
59
|
-
```puppet
|
60
|
-
class { 'klass':
|
61
|
-
param1 => 1,
|
62
|
-
param3 => 'foo',
|
63
|
-
}
|
64
|
-
```
|
65
|
-
|
66
|
-
##### This is another example
|
67
|
-
|
68
|
-
```puppet
|
69
|
-
class { 'klass':
|
70
|
-
param1 => 1,
|
71
|
-
param3 => 'foo',
|
72
|
-
}
|
73
|
-
```
|
74
|
-
|
75
|
-
#### Parameters
|
76
|
-
|
77
|
-
The following parameters are available in the `klass` class.
|
78
|
-
|
79
|
-
##### `param1`
|
80
|
-
|
81
|
-
Data type: `Integer`
|
82
|
-
|
83
|
-
First param.
|
84
|
-
|
85
|
-
Default value: 1
|
86
|
-
|
87
|
-
##### `param2`
|
88
|
-
|
89
|
-
Data type: `Any`
|
90
|
-
|
91
|
-
Second param.
|
92
|
-
|
93
|
-
Options:
|
94
|
-
|
95
|
-
* **:opt1** `String`: something about opt1
|
96
|
-
* **:opt2** `Hash`: a hash of stuff
|
97
|
-
|
98
|
-
Default value: `undef`
|
99
|
-
|
100
|
-
##### `param3`
|
101
|
-
|
102
|
-
Data type: `String`
|
103
|
-
|
104
|
-
Third param.
|
105
|
-
|
106
|
-
Default value: 'hi'
|
107
|
-
|
108
|
-
## Defined types
|
109
|
-
|
110
|
-
### klass::dt
|
111
|
-
|
112
|
-
An overview for a simple defined type.
|
113
|
-
|
114
|
-
* **Since** 1.1.0
|
115
|
-
|
116
|
-
* **See also**
|
117
|
-
www.puppet.com
|
118
|
-
|
119
|
-
#### Examples
|
120
|
-
|
121
|
-
##### Here's an example of this type:
|
122
|
-
|
123
|
-
```puppet
|
124
|
-
klass::dt { 'foo':
|
125
|
-
param1 => 33,
|
126
|
-
param4 => false,
|
127
|
-
}
|
128
|
-
```
|
129
|
-
|
130
|
-
#### Parameters
|
131
|
-
|
132
|
-
The following parameters are available in the `klass::dt` defined type.
|
133
|
-
|
134
|
-
##### `param1`
|
135
|
-
|
136
|
-
Data type: `Integer`
|
137
|
-
|
138
|
-
First param.
|
139
|
-
|
140
|
-
Default value: 44
|
141
|
-
|
142
|
-
##### `param2`
|
143
|
-
|
144
|
-
Data type: `Any`
|
145
|
-
|
146
|
-
Second param.
|
147
|
-
|
148
|
-
Options:
|
149
|
-
|
150
|
-
* **:opt1** `String`: something about opt1
|
151
|
-
* **:opt2** `Hash`: a hash of stuff
|
152
|
-
|
153
|
-
##### `param3`
|
154
|
-
|
155
|
-
Data type: `String`
|
156
|
-
|
157
|
-
Third param.
|
158
|
-
|
159
|
-
Default value: 'hi'
|
160
|
-
|
161
|
-
##### `param4`
|
162
|
-
|
163
|
-
Data type: `Boolean`
|
164
|
-
|
165
|
-
Fourth param.
|
166
|
-
|
167
|
-
Default value: `true`
|
168
|
-
|
169
|
-
## Resource types
|
170
|
-
|
171
|
-
### apt_key
|
172
|
-
|
173
|
-
This type provides Puppet with the capabilities to manage GPG keys needed
|
174
|
-
by apt to perform package validation. Apt has it's own GPG keyring that can
|
175
|
-
be manipulated through the `apt-key` command.
|
176
|
-
**Autorequires**:
|
177
|
-
If Puppet is given the location of a key file which looks like an absolute
|
178
|
-
path this type will autorequire that file.
|
179
|
-
|
180
|
-
#### Examples
|
181
|
-
|
182
|
-
##### here's an example
|
183
|
-
|
184
|
-
```puppet
|
185
|
-
apt_key { '6F6B15509CF8E59E6E469F327F438280EF8D349F':
|
186
|
-
source => 'http://apt.puppetlabs.com/pubkey.gpg'
|
187
|
-
}
|
188
|
-
```
|
189
|
-
|
190
|
-
#### Properties
|
191
|
-
|
192
|
-
The following properties are available in the `apt_key` type.
|
193
|
-
|
194
|
-
##### `ensure`
|
195
|
-
|
196
|
-
Data type: `Enum[present, absent]`
|
197
|
-
|
198
|
-
Whether this apt key should be present or absent on the target system.
|
199
|
-
|
200
|
-
##### `created`
|
201
|
-
|
202
|
-
Data type: `String`
|
203
|
-
|
204
|
-
Date the key was created, in ISO format.
|
205
|
-
|
206
|
-
#### Parameters
|
207
|
-
|
208
|
-
The following parameters are available in the `apt_key` type.
|
209
|
-
|
210
|
-
##### `id`
|
211
|
-
|
212
|
-
namevar
|
213
|
-
|
214
|
-
Data type: `Variant[Pattern[/A(0x)?[0-9a-fA-F]{8}Z/], Pattern[/A(0x)?[0-9a-fA-F]{16}Z/], Pattern[/A(0x)?[0-9a-fA-F]{40}Z/]]`
|
215
|
-
_*this data type contains a regex that may not be accurately reflected in generated documentation_
|
216
|
-
|
217
|
-
The ID of the key you want to manage.
|
218
|
-
|
219
|
-
### database
|
220
|
-
|
221
|
-
An example database server type.
|
222
|
-
|
223
|
-
#### Examples
|
224
|
-
|
225
|
-
##### here's an example
|
226
|
-
|
227
|
-
```puppet
|
228
|
-
database { 'foo':
|
229
|
-
address => 'qux.baz.bar',
|
230
|
-
}
|
231
|
-
```
|
232
|
-
|
233
|
-
#### Properties
|
234
|
-
|
235
|
-
The following properties are available in the `database` type.
|
236
|
-
|
237
|
-
##### `ensure`
|
238
|
-
|
239
|
-
Valid values: present, absent, up, down
|
240
|
-
|
241
|
-
Aliases: "up"=>"present", "down"=>"absent"
|
242
|
-
|
243
|
-
What state the database should be in.
|
244
|
-
|
245
|
-
Default value: up
|
246
|
-
|
247
|
-
##### `file`
|
248
|
-
|
249
|
-
The database file to use.
|
250
|
-
|
251
|
-
##### `log_level`
|
252
|
-
|
253
|
-
Valid values: debug, warn, error
|
254
|
-
|
255
|
-
The log level to use.
|
256
|
-
|
257
|
-
Default value: warn
|
258
|
-
|
259
|
-
#### Parameters
|
260
|
-
|
261
|
-
The following parameters are available in the `database` type.
|
262
|
-
|
263
|
-
##### `address`
|
264
|
-
|
265
|
-
namevar
|
266
|
-
|
267
|
-
The database server name.
|
268
|
-
|
269
|
-
##### `encryption_key`
|
270
|
-
|
271
|
-
The encryption key to use.
|
272
|
-
|
273
|
-
Required features: encryption.
|
274
|
-
|
275
|
-
##### `encrypt`
|
276
|
-
|
277
|
-
Valid values: `true`, `false`, yes, no
|
278
|
-
|
279
|
-
Whether or not to encrypt the database.
|
280
|
-
|
281
|
-
Default value: `false`
|
282
|
-
|
283
|
-
## Functions
|
284
|
-
|
285
|
-
### func
|
286
|
-
|
287
|
-
Type: Puppet Language
|
288
|
-
|
289
|
-
A simple Puppet function.
|
290
|
-
|
291
|
-
#### Examples
|
292
|
-
|
293
|
-
##### Test
|
294
|
-
|
295
|
-
```puppet
|
296
|
-
$result = func(1, 2)
|
297
|
-
```
|
298
|
-
|
299
|
-
#### `func(Integer $param1, Any $param2, String $param3 = hi)`
|
300
|
-
|
301
|
-
A simple Puppet function.
|
302
|
-
|
303
|
-
Returns: `Undef` Returns nothing.
|
304
|
-
|
305
|
-
Raises:
|
306
|
-
* `SomeError` this is some error
|
307
|
-
|
308
|
-
##### Examples
|
309
|
-
|
310
|
-
###### Test
|
311
|
-
|
312
|
-
```puppet
|
313
|
-
$result = func(1, 2)
|
314
|
-
```
|
315
|
-
|
316
|
-
##### `param1`
|
317
|
-
|
318
|
-
Data type: `Integer`
|
319
|
-
|
320
|
-
First param.
|
321
|
-
|
322
|
-
##### `param2`
|
323
|
-
|
324
|
-
Data type: `Any`
|
325
|
-
|
326
|
-
Second param.
|
327
|
-
|
328
|
-
##### `param3`
|
329
|
-
|
330
|
-
Data type: `String`
|
331
|
-
|
332
|
-
Third param.
|
333
|
-
|
334
|
-
Options:
|
335
|
-
|
336
|
-
* **:param3opt** `Array`: Something about this option
|
337
|
-
|
338
|
-
### func3x
|
339
|
-
|
340
|
-
Type: Ruby 3.x API
|
341
|
-
|
342
|
-
Documentation for an example 3.x function.
|
343
|
-
|
344
|
-
#### Examples
|
345
|
-
|
346
|
-
##### Calling the function.
|
347
|
-
|
348
|
-
```puppet
|
349
|
-
func3x('hi', 10)
|
350
|
-
```
|
351
|
-
|
352
|
-
#### `func3x(String $param1, Integer $param2)`
|
353
|
-
|
354
|
-
Documentation for an example 3.x function.
|
355
|
-
|
356
|
-
Returns: `Undef`
|
357
|
-
|
358
|
-
##### Examples
|
359
|
-
|
360
|
-
###### Calling the function.
|
361
|
-
|
362
|
-
```puppet
|
363
|
-
func3x('hi', 10)
|
364
|
-
```
|
365
|
-
|
366
|
-
##### `param1`
|
367
|
-
|
368
|
-
Data type: `String`
|
369
|
-
|
370
|
-
The first parameter.
|
371
|
-
|
372
|
-
##### `param2`
|
373
|
-
|
374
|
-
Data type: `Integer`
|
375
|
-
|
376
|
-
The second parameter.
|
377
|
-
|
378
|
-
### func4x
|
379
|
-
|
380
|
-
Type: Ruby 4.x API
|
381
|
-
|
382
|
-
An example 4.x function.
|
383
|
-
|
384
|
-
#### Examples
|
385
|
-
|
386
|
-
##### Calling the function
|
387
|
-
|
388
|
-
```puppet
|
389
|
-
$result = func4x(1, 'foo')
|
390
|
-
```
|
391
|
-
|
392
|
-
##### Calling the function with all args
|
393
|
-
|
394
|
-
```puppet
|
395
|
-
$result = func4x(1, 'foo', ['bar'])
|
396
|
-
```
|
397
|
-
|
398
|
-
#### `func4x(Integer $param1, Any $param2, Optional[Array[String]] $param3)`
|
399
|
-
|
400
|
-
An overview for the first overload.
|
401
|
-
|
402
|
-
Returns: `Undef` Returns nothing.
|
403
|
-
|
404
|
-
##### Examples
|
405
|
-
|
406
|
-
###### Calling the function foo
|
407
|
-
|
408
|
-
```puppet
|
409
|
-
$result = func4x(1, 'foooo')
|
410
|
-
```
|
411
|
-
|
412
|
-
##### `param1`
|
413
|
-
|
414
|
-
Data type: `Integer`
|
415
|
-
|
416
|
-
The first parameter.
|
417
|
-
|
418
|
-
##### `param2`
|
419
|
-
|
420
|
-
Data type: `Any`
|
421
|
-
|
422
|
-
The second parameter.
|
423
|
-
|
424
|
-
Options:
|
425
|
-
|
426
|
-
* **:option** `String`: an option
|
427
|
-
* **:option2** `String`: another option
|
428
|
-
|
429
|
-
##### `param3`
|
430
|
-
|
431
|
-
Data type: `Optional[Array[String]]`
|
432
|
-
|
433
|
-
The third parameter.
|
434
|
-
|
435
|
-
#### `func4x(Boolean $param, Callable &$block)`
|
436
|
-
|
437
|
-
An overview for the second overload.
|
438
|
-
|
439
|
-
Returns: `String` Returns a string.
|
440
|
-
|
441
|
-
##### Examples
|
442
|
-
|
443
|
-
###### Calling the function bar
|
444
|
-
|
445
|
-
```puppet
|
446
|
-
$result = func4x(1, 'bar', ['foo'])
|
447
|
-
```
|
448
|
-
|
449
|
-
##### `param`
|
450
|
-
|
451
|
-
Data type: `Boolean`
|
452
|
-
|
453
|
-
The first parameter.
|
454
|
-
|
455
|
-
##### `&block`
|
456
|
-
|
457
|
-
Data type: `Callable`
|
458
|
-
|
459
|
-
The block parameter.
|
460
|
-
|
461
|
-
### func4x_1
|
462
|
-
|
463
|
-
Type: Ruby 4.x API
|
464
|
-
|
465
|
-
An example 4.x function with only one signature.
|
466
|
-
|
467
|
-
#### `func4x_1(Integer $param1)`
|
468
|
-
|
469
|
-
An example 4.x function with only one signature.
|
470
|
-
|
471
|
-
Returns: `Undef` Returns nothing.
|
472
|
-
|
473
|
-
##### `param1`
|
474
|
-
|
475
|
-
Data type: `Integer`
|
476
|
-
|
477
|
-
The first parameter.
|
478
|
-
|
479
|
-
## Tasks
|
480
|
-
|
481
|
-
### (stdin)
|
482
|
-
|
483
|
-
Allows you to backup your database to local file.
|
484
|
-
|
485
|
-
**Supports noop?** false
|
486
|
-
|
487
|
-
#### Parameters
|
488
|
-
|
489
|
-
##### `database`
|
490
|
-
|
491
|
-
Data type: `Optional[String[1]]`
|
492
|
-
|
493
|
-
Database to connect to
|
494
|
-
|
495
|
-
##### `user`
|
496
|
-
|
497
|
-
Data type: `Optional[String[1]]`
|
498
|
-
|
499
|
-
The user
|
500
|
-
|
501
|
-
##### `password`
|
502
|
-
|
503
|
-
Data type: `Optional[String[1]]`
|
504
|
-
|
505
|
-
The password
|
506
|
-
|
507
|
-
##### `sql`
|
508
|
-
|
509
|
-
Data type: `String[1]`
|
510
|
-
|
511
|
-
Path to file you want backup to
|
512
|
-
|
513
|
-
## Plans
|
514
|
-
|
515
|
-
### plann
|
516
|
-
|
517
|
-
A simple plan.
|
518
|
-
|
519
|
-
#### Parameters
|
520
|
-
|
521
|
-
The following parameters are available in the `plann` plan.
|
522
|
-
|
523
|
-
##### `param1`
|
524
|
-
|
525
|
-
Data type: `String`
|
526
|
-
|
527
|
-
First param.
|
528
|
-
|
529
|
-
##### `param2`
|
530
|
-
|
531
|
-
Data type: `Any`
|
532
|
-
|
533
|
-
Second param.
|
534
|
-
|
535
|
-
##### `param3`
|
536
|
-
|
537
|
-
Data type: `Integer`
|
538
|
-
|
539
|
-
Third param.
|
540
|
-
|
541
|
-
Default value: 1
|
542
|
-
|