|
<style> |
|
.overview{ |
|
font: 1.82em; |
|
font-weight: bold; |
|
} |
|
body{ |
|
background: white; |
|
color: black; |
|
font-family: 'Lato', 'Ubuntu', 'Lucida Grande', 'Segoe UI', 'Arial', sans-serif; |
|
width: 100%; |
|
} |
|
h1{ |
|
background-color: #F6F6F6; |
|
color: #589632; |
|
font-size: x-large; |
|
font-weight: normal; |
|
background: none; |
|
padding: 0.75em 0 0; |
|
margin: 0; |
|
line-height: 3em; |
|
} |
|
h2{ |
|
background-color: #F6F6F6; |
|
color: #589632; |
|
font-size: medium; |
|
font-weight: normal; |
|
background: none; |
|
padding: 0.75em 0 0; |
|
margin: 0; |
|
line-height: 1.1em; |
|
} |
|
h3{ |
|
background-color: #F6F6F6; |
|
color: #93b023; |
|
font-weight: bold; |
|
font-size: large; |
|
text-align: left; |
|
border-bottom: 5px solid #DCEB5C; |
|
} |
|
h4{ |
|
background-color: #F6F6F6; |
|
color: #93b023; |
|
font-weight: bold; |
|
font-size: medium; |
|
text-align: left; |
|
} |
|
h5{ |
|
background-color: #F6F6F6; |
|
color: #93b023; |
|
font-weight: bold; |
|
font-size: small; |
|
text-align: left; |
|
} |
|
a{ |
|
color: #729FCF; |
|
font-family: arial,sans-serif; |
|
} |
|
label{ |
|
background-color: #FFFFCC; |
|
border: 1px solid black; |
|
margin: 1px; |
|
padding: 0px 3px; |
|
font-size: small; |
|
} |
|
th .strong { |
|
font-weight: bold; |
|
} |
|
hr { |
|
border: 0; |
|
height: 0; |
|
border-top: 1px solid black; |
|
} |
|
.list-view .highlight { |
|
text-align: left; |
|
border: 0px; |
|
width: 20%; |
|
padding-right: 15px; |
|
padding-left: 20px; |
|
font-weight: bold; |
|
} |
|
.tabular-view .odd-row { |
|
background-color: #f9f9f9; |
|
} |
|
.section { |
|
font-weight: bold; |
|
padding-top:25px; |
|
} |
|
|
|
|
|
|
|
.tabular-view{ |
|
border-collapse: collapse; |
|
width: 95%; |
|
} |
|
.tabular-view th, .tabular-view td { |
|
border:10px solid black; |
|
} |
|
|
|
|
|
.overview{ |
|
font: 1.82em; |
|
font-weight: bold; |
|
} |
|
body{ |
|
background: white; |
|
color: black; |
|
font-family: 'Lato', 'Ubuntu', 'Lucida Grande', 'Segoe UI', 'Arial', sans-serif; |
|
width: 100%; |
|
} |
|
h1{ |
|
background-color: #F6F6F6; |
|
color: #589632; |
|
font-size: x-large; |
|
font-weight: normal; |
|
background: none; |
|
padding: 0.75em 0 0; |
|
margin: 0; |
|
line-height: 3em; |
|
} |
|
h2{ |
|
background-color: #F6F6F6; |
|
color: #589632; |
|
font-size: medium; |
|
font-weight: normal; |
|
background: none; |
|
padding: 0.75em 0 0; |
|
margin: 0; |
|
line-height: 1.1em; |
|
} |
|
h3{ |
|
background-color: #F6F6F6; |
|
color: #93b023; |
|
font-weight: bold; |
|
font-size: large; |
|
text-align: left; |
|
border-bottom: 5px solid #DCEB5C; |
|
} |
|
h4{ |
|
background-color: #F6F6F6; |
|
color: #93b023; |
|
font-weight: bold; |
|
font-size: medium; |
|
text-align: left; |
|
} |
|
h5{ |
|
background-color: #F6F6F6; |
|
color: #93b023; |
|
font-weight: bold; |
|
font-size: small; |
|
text-align: left; |
|
} |
|
a{ |
|
color: #729FCF; |
|
font-family: arial,sans-serif; |
|
} |
|
label{ |
|
background-color: #FFFFCC; |
|
border: 1px solid black; |
|
margin: 1px; |
|
padding: 0px 3px; |
|
font-size: small; |
|
} |
|
th .strong { |
|
font-weight: bold; |
|
} |
|
hr { |
|
border: 0; |
|
height: 0; |
|
border-top: 1px solid black; |
|
} |
|
.list-view .highlight { |
|
text-align: left; |
|
border: 0px; |
|
width: 20%; |
|
padding-right: 15px; |
|
padding-left: 20px; |
|
font-weight: bold; |
|
} |
|
.tabular-view .odd-row { |
|
background-color: #f9f9f9; |
|
} |
|
.section { |
|
font-weight: bold; |
|
padding-top:25px; |
|
} |
|
|
|
body { |
|
margin-left: 50px; |
|
} |
|
.group { |
|
margin-bottom: 30px; |
|
} |
|
.function { |
|
margin-left: 20px; |
|
} |
|
</style> |
|
<h1>Expressions documentation single page (locale es)</h1> |
|
<a href="#aggregates"><h2 id="aggregates-idx">Agregados</h2></a><ul><li><a href="#aggregates-aggregate"><span id="aggregates-aggregate-idx">aggregate</span></a></li><li><a href="#aggregates-array_agg"><span id="aggregates-array_agg-idx">array_agg</span></a></li><li><a href="#aggregates-collect"><span id="aggregates-collect-idx">collect</span></a></li><li><a href="#aggregates-concatenate"><span id="aggregates-concatenate-idx">concatenate</span></a></li><li><a href="#aggregates-concatenate_unique"><span id="aggregates-concatenate_unique-idx">concatenate_unique</span></a></li><li><a href="#aggregates-count"><span id="aggregates-count-idx">count</span></a></li><li><a href="#aggregates-count_distinct"><span id="aggregates-count_distinct-idx">count_distinct</span></a></li><li><a href="#aggregates-count_missing"><span id="aggregates-count_missing-idx">count_missing</span></a></li><li><a href="#aggregates-iqr"><span id="aggregates-iqr-idx">iqr</span></a></li><li><a href="#aggregates-majority"><span id="aggregates-majority-idx">majority</span></a></li><li><a href="#aggregates-max_length"><span id="aggregates-max_length-idx">max_length</span></a></li><li><a href="#aggregates-maximum"><span id="aggregates-maximum-idx">maximum</span></a></li><li><a href="#aggregates-mean"><span id="aggregates-mean-idx">mean</span></a></li><li><a href="#aggregates-median"><span id="aggregates-median-idx">median</span></a></li><li><a href="#aggregates-min_length"><span id="aggregates-min_length-idx">min_length</span></a></li><li><a href="#aggregates-minimum"><span id="aggregates-minimum-idx">minimum</span></a></li><li><a href="#aggregates-minority"><span id="aggregates-minority-idx">minority</span></a></li><li><a href="#aggregates-q1"><span id="aggregates-q1-idx">q1</span></a></li><li><a href="#aggregates-q3"><span id="aggregates-q3-idx">q3</span></a></li><li><a href="#aggregates-range"><span id="aggregates-range-idx">range</span></a></li><li><a href="#aggregates-relation_aggregate"><span id="aggregates-relation_aggregate-idx">relation_aggregate</span></a></li><li><a href="#aggregates-stdev"><span id="aggregates-stdev-idx">stdev</span></a></li><li><a href="#aggregates-sum"><span id="aggregates-sum-idx">sum</span></a></li></ul><a href="#arrays"><h2 id="arrays-idx">Matrices</h2></a><ul><li><a href="#arrays-array"><span id="arrays-array-idx">array</span></a></li><li><a href="#arrays-array_all"><span id="arrays-array_all-idx">array_all</span></a></li><li><a href="#arrays-array_append"><span id="arrays-array_append-idx">array_append</span></a></li><li><a href="#arrays-array_cat"><span id="arrays-array_cat-idx">array_cat</span></a></li><li><a href="#arrays-array_contains"><span id="arrays-array_contains-idx">array_contains</span></a></li><li><a href="#arrays-array_distinct"><span id="arrays-array_distinct-idx">array_distinct</span></a></li><li><a href="#arrays-array_filter"><span id="arrays-array_filter-idx">array_filter</span></a></li><li><a href="#arrays-array_find"><span id="arrays-array_find-idx">array_find</span></a></li><li><a href="#arrays-array_first"><span id="arrays-array_first-idx">array_first</span></a></li><li><a href="#arrays-array_foreach"><span id="arrays-array_foreach-idx">array_foreach</span></a></li><li><a href="#arrays-array_get"><span id="arrays-array_get-idx">array_get</span></a></li><li><a href="#arrays-array_insert"><span id="arrays-array_insert-idx">array_insert</span></a></li><li><a href="#arrays-array_intersect"><span id="arrays-array_intersect-idx">array_intersect</span></a></li><li><a href="#arrays-array_last"><span id="arrays-array_last-idx">array_last</span></a></li><li><a href="#arrays-array_length"><span id="arrays-array_length-idx">array_length</span></a></li><li><a href="#arrays-array_prepend"><span id="arrays-array_prepend-idx">array_prepend</span></a></li><li><a href="#arrays-array_remove_all"><span id="arrays-array_remove_all-idx">array_remove_all</span></a></li><li><a href="#arrays-array_remove_at"><span id="arrays-array_remove_at-idx">array_remove_at</span></a></li><li><a href="#arrays-array_reverse"><span id="arrays-array_reverse-idx">array_reverse</span></a></li><li><a href="#arrays-array_slice"><span id="arrays-array_slice-idx">array_slice</span></a></li><li><a href="#arrays-array_sort"><span id="arrays-array_sort-idx">array_sort</span></a></li><li><a href="#arrays-array_to_string"><span id="arrays-array_to_string-idx">array_to_string</span></a></li><li><a href="#arrays-generate_series"><span id="arrays-generate_series-idx">generate_series</span></a></li><li><a href="#arrays-regexp_matches"><span id="arrays-regexp_matches-idx">regexp_matches</span></a></li><li><a href="#arrays-string_to_array"><span id="arrays-string_to_array-idx">string_to_array</span></a></li></ul><a href="#color"><h2 id="color-idx">Color</h2></a><ul><li><a href="#color-color_cmyk"><span id="color-color_cmyk-idx">color_cmyk</span></a></li><li><a href="#color-color_cmyka"><span id="color-color_cmyka-idx">color_cmyka</span></a></li><li><a href="#color-color_grayscale_average"><span id="color-color_grayscale_average-idx">color_grayscale_average</span></a></li><li><a href="#color-color_hsl"><span id="color-color_hsl-idx">color_hsl</span></a></li><li><a href="#color-color_hsla"><span id="color-color_hsla-idx">color_hsla</span></a></li><li><a href="#color-color_hsv"><span id="color-color_hsv-idx">color_hsv</span></a></li><li><a href="#color-color_hsva"><span id="color-color_hsva-idx">color_hsva</span></a></li><li><a href="#color-color_mix_rgb"><span id="color-color_mix_rgb-idx">color_mix_rgb</span></a></li><li><a href="#color-color_part"><span id="color-color_part-idx">color_part</span></a></li><li><a href="#color-color_rgb"><span id="color-color_rgb-idx">color_rgb</span></a></li><li><a href="#color-color_rgba"><span id="color-color_rgba-idx">color_rgba</span></a></li><li><a href="#color-create_ramp"><span id="color-create_ramp-idx">create_ramp</span></a></li><li><a href="#color-darker"><span id="color-darker-idx">darker</span></a></li><li><a href="#color-lighter"><span id="color-lighter-idx">lighter</span></a></li><li><a href="#color-project_color"><span id="color-project_color-idx">project_color</span></a></li><li><a href="#color-ramp_color"><span id="color-ramp_color-idx">ramp_color</span></a></li><li><a href="#color-set_color_part"><span id="color-set_color_part-idx">set_color_part</span></a></li></ul><a href="#conditionals"><h2 id="conditionals-idx">Condicionales</h2></a><ul><li><a href="#conditionals-coalesce"><span id="conditionals-coalesce-idx">coalesce</span></a></li><li><a href="#conditionals-if"><span id="conditionals-if-idx">if</span></a></li><li><a href="#conditionals-nullif"><span id="conditionals-nullif-idx">nullif</span></a></li><li><a href="#conditionals-regexp_match"><span id="conditionals-regexp_match-idx">regexp_match</span></a></li><li><a href="#conditionals-try"><span id="conditionals-try-idx">try</span></a></li></ul><a href="#conversions"><h2 id="conversions-idx">Conversiones</h2></a><ul><li><a href="#conversions-from_base64"><span id="conversions-from_base64-idx">from_base64</span></a></li><li><a href="#conversions-hash"><span id="conversions-hash-idx">hash</span></a></li><li><a href="#conversions-md5"><span id="conversions-md5-idx">md5</span></a></li><li><a href="#conversions-sha256"><span id="conversions-sha256-idx">sha256</span></a></li><li><a href="#conversions-to_base64"><span id="conversions-to_base64-idx">to_base64</span></a></li><li><a href="#conversions-to_date"><span id="conversions-to_date-idx">to_date</span></a></li><li><a href="#conversions-to_datetime"><span id="conversions-to_datetime-idx">to_datetime</span></a></li><li><a href="#conversions-to_dm"><span id="conversions-to_dm-idx">to_dm</span></a></li><li><a href="#conversions-to_dms"><span id="conversions-to_dms-idx">to_dms</span></a></li><li><a href="#conversions-to_int"><span id="conversions-to_int-idx">to_int</span></a></li><li><a href="#conversions-to_interval"><span id="conversions-to_interval-idx">to_interval</span></a></li><li><a href="#conversions-to_real"><span id="conversions-to_real-idx">to_real</span></a></li><li><a href="#conversions-to_string"><span id="conversions-to_string-idx">to_string</span></a></li><li><a href="#conversions-to_time"><span id="conversions-to_time-idx">to_time</span></a></li></ul><a href="#date-and-time"><h2 id="date-and-time-idx">Fecha y Hora</h2></a><ul><li><a href="#date-and-time-age"><span id="date-and-time-age-idx">age</span></a></li><li><a href="#date-and-time-datetime_from_epoch"><span id="date-and-time-datetime_from_epoch-idx">datetime_from_epoch</span></a></li><li><a href="#date-and-time-day"><span id="date-and-time-day-idx">day</span></a></li><li><a href="#date-and-time-day_of_week"><span id="date-and-time-day_of_week-idx">day_of_week</span></a></li><li><a href="#date-and-time-epoch"><span id="date-and-time-epoch-idx">epoch</span></a></li><li><a href="#date-and-time-format_date"><span id="date-and-time-format_date-idx">format_date</span></a></li><li><a href="#date-and-time-hour"><span id="date-and-time-hour-idx">hour</span></a></li><li><a href="#date-and-time-make_date"><span id="date-and-time-make_date-idx">make_date</span></a></li><li><a href="#date-and-time-make_datetime"><span id="date-and-time-make_datetime-idx">make_datetime</span></a></li><li><a href="#date-and-time-make_interval"><span id="date-and-time-make_interval-idx">make_interval</span></a></li><li><a href="#date-and-time-make_time"><span id="date-and-time-make_time-idx">make_time</span></a></li><li><a href="#date-and-time-minute"><span id="date-and-time-minute-idx">minute</span></a></li><li><a href="#date-and-time-month"><span id="date-and-time-month-idx">month</span></a></li><li><a href="#date-and-time-now"><span id="date-and-time-now-idx">now</span></a></li><li><a href="#date-and-time-second"><span id="date-and-time-second-idx">second</span></a></li><li><a href="#date-and-time-to_date"><span id="date-and-time-to_date-idx">to_date</span></a></li><li><a href="#date-and-time-to_datetime"><span id="date-and-time-to_datetime-idx">to_datetime</span></a></li><li><a href="#date-and-time-to_interval"><span id="date-and-time-to_interval-idx">to_interval</span></a></li><li><a href="#date-and-time-to_time"><span id="date-and-time-to_time-idx">to_time</span></a></li><li><a href="#date-and-time-week"><span id="date-and-time-week-idx">week</span></a></li><li><a href="#date-and-time-year"><span id="date-and-time-year-idx">year</span></a></li></ul><a href="#files-and-paths"><h2 id="files-and-paths-idx">Files and Paths</h2></a><ul><li><a href="#files-and-paths-base_file_name"><span id="files-and-paths-base_file_name-idx">base_file_name</span></a></li><li><a href="#files-and-paths-file_exists"><span id="files-and-paths-file_exists-idx">file_exists</span></a></li><li><a href="#files-and-paths-file_name"><span id="files-and-paths-file_name-idx">file_name</span></a></li><li><a href="#files-and-paths-file_path"><span id="files-and-paths-file_path-idx">file_path</span></a></li><li><a href="#files-and-paths-file_size"><span id="files-and-paths-file_size-idx">file_size</span></a></li><li><a href="#files-and-paths-file_suffix"><span id="files-and-paths-file_suffix-idx">file_suffix</span></a></li><li><a href="#files-and-paths-is_directory"><span id="files-and-paths-is_directory-idx">is_directory</span></a></li><li><a href="#files-and-paths-is_file"><span id="files-and-paths-is_file-idx">is_file</span></a></li></ul><a href="#form"><h2 id="form-idx">Formulario</h2></a><ul><li><a href="#form-current_parent_value"><span id="form-current_parent_value-idx">current_parent_value</span></a></li><li><a href="#form-current_value"><span id="form-current_value-idx">current_value</span></a></li></ul><a href="#fuzzy-matching"><h2 id="fuzzy-matching-idx">Concordancia aproximada</h2></a><ul><li><a href="#fuzzy-matching-hamming_distance"><span id="fuzzy-matching-hamming_distance-idx">hamming_distance</span></a></li><li><a href="#fuzzy-matching-levenshtein"><span id="fuzzy-matching-levenshtein-idx">levenshtein</span></a></li><li><a href="#fuzzy-matching-longest_common_substring"><span id="fuzzy-matching-longest_common_substring-idx">longest_common_substring</span></a></li><li><a href="#fuzzy-matching-soundex"><span id="fuzzy-matching-soundex-idx">soundex</span></a></li></ul><a href="#general"><h2 id="general-idx">General</h2></a><ul><li><a href="#general-env"><span id="general-env-idx">env</span></a></li><li><a href="#general-eval"><span id="general-eval-idx">eval</span></a></li><li><a href="#general-eval_template"><span id="general-eval_template-idx">eval_template</span></a></li><li><a href="#general-is_layer_visible"><span id="general-is_layer_visible-idx">is_layer_visible</span></a></li><li><a href="#general-layer_property"><span id="general-layer_property-idx">layer_property</span></a></li><li><a href="#general-var"><span id="general-var-idx">var</span></a></li><li><a href="#general-with_variable"><span id="general-with_variable-idx">with_variable</span></a></li></ul><a href="#geometrygroup"><h2 id="geometrygroup-idx">Geometría</h2></a><ul><li><a href="#geometrygroup-dollar-area"><span id="geometrygroup-dollar-area-idx">$area</span></a></li><li><a href="#geometrygroup-dollar-geometry"><span id="geometrygroup-dollar-geometry-idx">$geometry</span></a></li><li><a href="#geometrygroup-dollar-length"><span id="geometrygroup-dollar-length-idx">$length</span></a></li><li><a href="#geometrygroup-dollar-perimeter"><span id="geometrygroup-dollar-perimeter-idx">$perimeter</span></a></li><li><a href="#geometrygroup-dollar-x"><span id="geometrygroup-dollar-x-idx">$x</span></a></li><li><a href="#geometrygroup-dollar-x_at"><span id="geometrygroup-dollar-x_at-idx">$x_at</span></a></li><li><a href="#geometrygroup-dollar-y"><span id="geometrygroup-dollar-y-idx">$y</span></a></li><li><a href="#geometrygroup-dollar-y_at"><span id="geometrygroup-dollar-y_at-idx">$y_at</span></a></li><li><a href="#geometrygroup-angle_at_vertex"><span id="geometrygroup-angle_at_vertex-idx">angle_at_vertex</span></a></li><li><a href="#geometrygroup-area"><span id="geometrygroup-area-idx">area</span></a></li><li><a href="#geometrygroup-azimuth"><span id="geometrygroup-azimuth-idx">azimuth</span></a></li><li><a href="#geometrygroup-boundary"><span id="geometrygroup-boundary-idx">boundary</span></a></li><li><a href="#geometrygroup-bounds"><span id="geometrygroup-bounds-idx">bounds</span></a></li><li><a href="#geometrygroup-bounds_height"><span id="geometrygroup-bounds_height-idx">bounds_height</span></a></li><li><a href="#geometrygroup-bounds_width"><span id="geometrygroup-bounds_width-idx">bounds_width</span></a></li><li><a href="#geometrygroup-buffer"><span id="geometrygroup-buffer-idx">buffer</span></a></li><li><a href="#geometrygroup-buffer_by_m"><span id="geometrygroup-buffer_by_m-idx">buffer_by_m</span></a></li><li><a href="#geometrygroup-centroid"><span id="geometrygroup-centroid-idx">centroid</span></a></li><li><a href="#geometrygroup-close_line"><span id="geometrygroup-close_line-idx">close_line</span></a></li><li><a href="#geometrygroup-closest_point"><span id="geometrygroup-closest_point-idx">closest_point</span></a></li><li><a href="#geometrygroup-collect_geometries"><span id="geometrygroup-collect_geometries-idx">collect_geometries</span></a></li><li><a href="#geometrygroup-combine"><span id="geometrygroup-combine-idx">combine</span></a></li><li><a href="#geometrygroup-contains"><span id="geometrygroup-contains-idx">contains</span></a></li><li><a href="#geometrygroup-convex_hull"><span id="geometrygroup-convex_hull-idx">convex_hull</span></a></li><li><a href="#geometrygroup-crosses"><span id="geometrygroup-crosses-idx">crosses</span></a></li><li><a href="#geometrygroup-difference"><span id="geometrygroup-difference-idx">difference</span></a></li><li><a href="#geometrygroup-disjoint"><span id="geometrygroup-disjoint-idx">disjoint</span></a></li><li><a href="#geometrygroup-distance"><span id="geometrygroup-distance-idx">distance</span></a></li><li><a href="#geometrygroup-distance_to_vertex"><span id="geometrygroup-distance_to_vertex-idx">distance_to_vertex</span></a></li><li><a href="#geometrygroup-end_point"><span id="geometrygroup-end_point-idx">end_point</span></a></li><li><a href="#geometrygroup-extend"><span id="geometrygroup-extend-idx">extend</span></a></li><li><a href="#geometrygroup-exterior_ring"><span id="geometrygroup-exterior_ring-idx">exterior_ring</span></a></li><li><a href="#geometrygroup-extrude"><span id="geometrygroup-extrude-idx">extrude</span></a></li><li><a href="#geometrygroup-flip_coordinates"><span id="geometrygroup-flip_coordinates-idx">flip_coordinates</span></a></li><li><a href="#geometrygroup-force_rhr"><span id="geometrygroup-force_rhr-idx">force_rhr</span></a></li><li><a href="#geometrygroup-geom_from_gml"><span id="geometrygroup-geom_from_gml-idx">geom_from_gml</span></a></li><li><a href="#geometrygroup-geom_from_wkb"><span id="geometrygroup-geom_from_wkb-idx">geom_from_wkb</span></a></li><li><a href="#geometrygroup-geom_from_wkt"><span id="geometrygroup-geom_from_wkt-idx">geom_from_wkt</span></a></li><li><a href="#geometrygroup-geom_to_wkb"><span id="geometrygroup-geom_to_wkb-idx">geom_to_wkb</span></a></li><li><a href="#geometrygroup-geom_to_wkt"><span id="geometrygroup-geom_to_wkt-idx">geom_to_wkt</span></a></li><li><a href="#geometrygroup-geometry"><span id="geometrygroup-geometry-idx">geometry</span></a></li><li><a href="#geometrygroup-geometry_n"><span id="geometrygroup-geometry_n-idx">geometry_n</span></a></li><li><a href="#geometrygroup-hausdorff_distance"><span id="geometrygroup-hausdorff_distance-idx">hausdorff_distance</span></a></li><li><a href="#geometrygroup-inclination"><span id="geometrygroup-inclination-idx">inclination</span></a></li><li><a href="#geometrygroup-interior_ring_n"><span id="geometrygroup-interior_ring_n-idx">interior_ring_n</span></a></li><li><a href="#geometrygroup-intersection"><span id="geometrygroup-intersection-idx">intersection</span></a></li><li><a href="#geometrygroup-intersects"><span id="geometrygroup-intersects-idx">intersects</span></a></li><li><a href="#geometrygroup-intersects_bbox"><span id="geometrygroup-intersects_bbox-idx">intersects_bbox</span></a></li><li><a href="#geometrygroup-is_closed"><span id="geometrygroup-is_closed-idx">is_closed</span></a></li><li><a href="#geometrygroup-is_empty"><span id="geometrygroup-is_empty-idx">is_empty</span></a></li><li><a href="#geometrygroup-is_empty_or_null"><span id="geometrygroup-is_empty_or_null-idx">is_empty_or_null</span></a></li><li><a href="#geometrygroup-is_multipart"><span id="geometrygroup-is_multipart-idx">is_multipart</span></a></li><li><a href="#geometrygroup-is_valid"><span id="geometrygroup-is_valid-idx">is_valid</span></a></li><li><a href="#geometrygroup-length"><span id="geometrygroup-length-idx">length</span></a></li><li><a href="#geometrygroup-line_interpolate_angle"><span id="geometrygroup-line_interpolate_angle-idx">line_interpolate_angle</span></a></li><li><a href="#geometrygroup-line_interpolate_point"><span id="geometrygroup-line_interpolate_point-idx">line_interpolate_point</span></a></li><li><a href="#geometrygroup-line_locate_point"><span id="geometrygroup-line_locate_point-idx">line_locate_point</span></a></li><li><a href="#geometrygroup-line_merge"><span id="geometrygroup-line_merge-idx">line_merge</span></a></li><li><a href="#geometrygroup-line_substring"><span id="geometrygroup-line_substring-idx">line_substring</span></a></li><li><a href="#geometrygroup-m"><span id="geometrygroup-m-idx">m</span></a></li><li><a href="#geometrygroup-m_max"><span id="geometrygroup-m_max-idx">m_max</span></a></li><li><a href="#geometrygroup-m_min"><span id="geometrygroup-m_min-idx">m_min</span></a></li><li><a href="#geometrygroup-make_circle"><span id="geometrygroup-make_circle-idx">make_circle</span></a></li><li><a href="#geometrygroup-make_ellipse"><span id="geometrygroup-make_ellipse-idx">make_ellipse</span></a></li><li><a href="#geometrygroup-make_line"><span id="geometrygroup-make_line-idx">make_line</span></a></li><li><a href="#geometrygroup-make_point"><span id="geometrygroup-make_point-idx">make_point</span></a></li><li><a href="#geometrygroup-make_point_m"><span id="geometrygroup-make_point_m-idx">make_point_m</span></a></li><li><a href="#geometrygroup-make_polygon"><span id="geometrygroup-make_polygon-idx">make_polygon</span></a></li><li><a href="#geometrygroup-make_rectangle_3points"><span id="geometrygroup-make_rectangle_3points-idx">make_rectangle_3points</span></a></li><li><a href="#geometrygroup-make_regular_polygon"><span id="geometrygroup-make_regular_polygon-idx">make_regular_polygon</span></a></li><li><a href="#geometrygroup-make_square"><span id="geometrygroup-make_square-idx">make_square</span></a></li><li><a href="#geometrygroup-make_triangle"><span id="geometrygroup-make_triangle-idx">make_triangle</span></a></li><li><a href="#geometrygroup-minimal_circle"><span id="geometrygroup-minimal_circle-idx">minimal_circle</span></a></li><li><a href="#geometrygroup-nodes_to_points"><span id="geometrygroup-nodes_to_points-idx">nodes_to_points</span></a></li><li><a href="#geometrygroup-num_geometries"><span id="geometrygroup-num_geometries-idx">num_geometries</span></a></li><li><a href="#geometrygroup-num_interior_rings"><span id="geometrygroup-num_interior_rings-idx">num_interior_rings</span></a></li><li><a href="#geometrygroup-num_points"><span id="geometrygroup-num_points-idx">num_points</span></a></li><li><a href="#geometrygroup-num_rings"><span id="geometrygroup-num_rings-idx">num_rings</span></a></li><li><a href="#geometrygroup-offset_curve"><span id="geometrygroup-offset_curve-idx">offset_curve</span></a></li><li><a href="#geometrygroup-order_parts"><span id="geometrygroup-order_parts-idx">order_parts</span></a></li><li><a href="#geometrygroup-oriented_bbox"><span id="geometrygroup-oriented_bbox-idx">oriented_bbox</span></a></li><li><a href="#geometrygroup-overlaps"><span id="geometrygroup-overlaps-idx">overlaps</span></a></li><li><a href="#geometrygroup-perimeter"><span id="geometrygroup-perimeter-idx">perimeter</span></a></li><li><a href="#geometrygroup-point_n"><span id="geometrygroup-point_n-idx">point_n</span></a></li><li><a href="#geometrygroup-point_on_surface"><span id="geometrygroup-point_on_surface-idx">point_on_surface</span></a></li><li><a href="#geometrygroup-pole_of_inaccessibility"><span id="geometrygroup-pole_of_inaccessibility-idx">pole_of_inaccessibility</span></a></li><li><a href="#geometrygroup-project"><span id="geometrygroup-project-idx">project</span></a></li><li><a href="#geometrygroup-relate"><span id="geometrygroup-relate-idx">relate</span></a></li><li><a href="#geometrygroup-reverse"><span id="geometrygroup-reverse-idx">reverse</span></a></li><li><a href="#geometrygroup-rotate"><span id="geometrygroup-rotate-idx">rotate</span></a></li><li><a href="#geometrygroup-segments_to_lines"><span id="geometrygroup-segments_to_lines-idx">segments_to_lines</span></a></li><li><a href="#geometrygroup-shortest_line"><span id="geometrygroup-shortest_line-idx">shortest_line</span></a></li><li><a href="#geometrygroup-simplify"><span id="geometrygroup-simplify-idx">simplify</span></a></li><li><a href="#geometrygroup-simplify_vw"><span id="geometrygroup-simplify_vw-idx">simplify_vw</span></a></li><li><a href="#geometrygroup-single_sided_buffer"><span id="geometrygroup-single_sided_buffer-idx">single_sided_buffer</span></a></li><li><a href="#geometrygroup-smooth"><span id="geometrygroup-smooth-idx">smooth</span></a></li><li><a href="#geometrygroup-start_point"><span id="geometrygroup-start_point-idx">start_point</span></a></li><li><a href="#geometrygroup-sym_difference"><span id="geometrygroup-sym_difference-idx">sym_difference</span></a></li><li><a href="#geometrygroup-tapered_buffer"><span id="geometrygroup-tapered_buffer-idx">tapered_buffer</span></a></li><li><a href="#geometrygroup-touches"><span id="geometrygroup-touches-idx">touches</span></a></li><li><a href="#geometrygroup-transform"><span id="geometrygroup-transform-idx">transform</span></a></li><li><a href="#geometrygroup-translate"><span id="geometrygroup-translate-idx">translate</span></a></li><li><a href="#geometrygroup-union"><span id="geometrygroup-union-idx">union</span></a></li><li><a href="#geometrygroup-wedge_buffer"><span id="geometrygroup-wedge_buffer-idx">wedge_buffer</span></a></li><li><a href="#geometrygroup-within"><span id="geometrygroup-within-idx">within</span></a></li><li><a href="#geometrygroup-x"><span id="geometrygroup-x-idx">x</span></a></li><li><a href="#geometrygroup-x_max"><span id="geometrygroup-x_max-idx">x_max</span></a></li><li><a href="#geometrygroup-x_min"><span id="geometrygroup-x_min-idx">x_min</span></a></li><li><a href="#geometrygroup-y"><span id="geometrygroup-y-idx">y</span></a></li><li><a href="#geometrygroup-y_max"><span id="geometrygroup-y_max-idx">y_max</span></a></li><li><a href="#geometrygroup-y_min"><span id="geometrygroup-y_min-idx">y_min</span></a></li><li><a href="#geometrygroup-z"><span id="geometrygroup-z-idx">z</span></a></li><li><a href="#geometrygroup-z_max"><span id="geometrygroup-z_max-idx">z_max</span></a></li><li><a href="#geometrygroup-z_min"><span id="geometrygroup-z_min-idx">z_min</span></a></li></ul><a href="#layout"><h2 id="layout-idx">Diseño</h2></a><ul><li><a href="#layout-item_variables"><span id="layout-item_variables-idx">item_variables</span></a></li></ul><a href="#map-layers"><h2 id="map-layers-idx">Capas de mapa</h2></a><ul><li><a href="#map-layers-decode_uri"><span id="map-layers-decode_uri-idx">decode_uri</span></a></li></ul><a href="#maps"><h2 id="maps-idx">Mapas</h2></a><ul><li><a href="#maps-from_json"><span id="maps-from_json-idx">from_json</span></a></li><li><a href="#maps-hstore_to_map"><span id="maps-hstore_to_map-idx">hstore_to_map</span></a></li><li><a href="#maps-json_to_map"><span id="maps-json_to_map-idx">json_to_map</span></a></li><li><a href="#maps-map"><span id="maps-map-idx">map</span></a></li><li><a href="#maps-map_akeys"><span id="maps-map_akeys-idx">map_akeys</span></a></li><li><a href="#maps-map_avals"><span id="maps-map_avals-idx">map_avals</span></a></li><li><a href="#maps-map_concat"><span id="maps-map_concat-idx">map_concat</span></a></li><li><a href="#maps-map_delete"><span id="maps-map_delete-idx">map_delete</span></a></li><li><a href="#maps-map_exist"><span id="maps-map_exist-idx">map_exist</span></a></li><li><a href="#maps-map_get"><span id="maps-map_get-idx">map_get</span></a></li><li><a href="#maps-map_insert"><span id="maps-map_insert-idx">map_insert</span></a></li><li><a href="#maps-map_to_hstore"><span id="maps-map_to_hstore-idx">map_to_hstore</span></a></li><li><a href="#maps-map_to_json"><span id="maps-map_to_json-idx">map_to_json</span></a></li><li><a href="#maps-to_json"><span id="maps-to_json-idx">to_json</span></a></li></ul><a href="#math"><h2 id="math-idx">Matemáticas</h2></a><ul><li><a href="#math-abs"><span id="math-abs-idx">abs</span></a></li><li><a href="#math-acos"><span id="math-acos-idx">acos</span></a></li><li><a href="#math-asin"><span id="math-asin-idx">asin</span></a></li><li><a href="#math-atan"><span id="math-atan-idx">atan</span></a></li><li><a href="#math-atan2"><span id="math-atan2-idx">atan2</span></a></li><li><a href="#math-azimuth"><span id="math-azimuth-idx">azimuth</span></a></li><li><a href="#math-ceil"><span id="math-ceil-idx">ceil</span></a></li><li><a href="#math-clamp"><span id="math-clamp-idx">clamp</span></a></li><li><a href="#math-cos"><span id="math-cos-idx">cos</span></a></li><li><a href="#math-degrees"><span id="math-degrees-idx">degrees</span></a></li><li><a href="#math-exp"><span id="math-exp-idx">exp</span></a></li><li><a href="#math-floor"><span id="math-floor-idx">floor</span></a></li><li><a href="#math-inclination"><span id="math-inclination-idx">inclination</span></a></li><li><a href="#math-ln"><span id="math-ln-idx">ln</span></a></li><li><a href="#math-log"><span id="math-log-idx">log</span></a></li><li><a href="#math-log10"><span id="math-log10-idx">log10</span></a></li><li><a href="#math-max"><span id="math-max-idx">max</span></a></li><li><a href="#math-min"><span id="math-min-idx">min</span></a></li><li><a href="#math-pi"><span id="math-pi-idx">pi</span></a></li><li><a href="#math-radians"><span id="math-radians-idx">radians</span></a></li><li><a href="#math-rand"><span id="math-rand-idx">rand</span></a></li><li><a href="#math-randf"><span id="math-randf-idx">randf</span></a></li><li><a href="#math-round"><span id="math-round-idx">round</span></a></li><li><a href="#math-scale_exp"><span id="math-scale_exp-idx">scale_exp</span></a></li><li><a href="#math-scale_linear"><span id="math-scale_linear-idx">scale_linear</span></a></li><li><a href="#math-sin"><span id="math-sin-idx">sin</span></a></li><li><a href="#math-sqrt"><span id="math-sqrt-idx">sqrt</span></a></li><li><a href="#math-tan"><span id="math-tan-idx">tan</span></a></li></ul><a href="#processing"><h2 id="processing-idx">Processing</h2></a><ul><li><a href="#processing-parameter"><span id="processing-parameter-idx">parameter</span></a></li></ul><a href="#python"><h2 id="python-idx">Python</h2></a><ul><li><a href="#python-dollar-mask_geometry"><span id="python-dollar-mask_geometry-idx">$mask_geometry</span></a></li><li><a href="#python-in_mask"><span id="python-in_mask-idx">in_mask</span></a></li></ul><a href="#rasters"><h2 id="rasters-idx">Rásters</h2></a><ul><li><a href="#rasters-raster_statistic"><span id="rasters-raster_statistic-idx">raster_statistic</span></a></li><li><a href="#rasters-raster_value"><span id="rasters-raster_value-idx">raster_value</span></a></li></ul><a href="#record-and-attributes"><h2 id="record-and-attributes-idx">Registros y atributos</h2></a><ul><li><a href="#record-and-attributes-dollar-currentfeature"><span id="record-and-attributes-dollar-currentfeature-idx">$currentfeature</span></a></li><li><a href="#record-and-attributes-dollar-id"><span id="record-and-attributes-dollar-id-idx">$id</span></a></li><li><a href="#record-and-attributes-attribute"><span id="record-and-attributes-attribute-idx">attribute</span></a></li><li><a href="#record-and-attributes-attributes"><span id="record-and-attributes-attributes-idx">attributes</span></a></li><li><a href="#record-and-attributes-display_expression"><span id="record-and-attributes-display_expression-idx">display_expression</span></a></li><li><a href="#record-and-attributes-get_feature"><span id="record-and-attributes-get_feature-idx">get_feature</span></a></li><li><a href="#record-and-attributes-get_feature_by_id"><span id="record-and-attributes-get_feature_by_id-idx">get_feature_by_id</span></a></li><li><a href="#record-and-attributes-is_selected"><span id="record-and-attributes-is_selected-idx">is_selected</span></a></li><li><a href="#record-and-attributes-maptip"><span id="record-and-attributes-maptip-idx">maptip</span></a></li><li><a href="#record-and-attributes-num_selected"><span id="record-and-attributes-num_selected-idx">num_selected</span></a></li><li><a href="#record-and-attributes-represent_value"><span id="record-and-attributes-represent_value-idx">represent_value</span></a></li><li><a href="#record-and-attributes-sqlite_fetch_and_increment"><span id="record-and-attributes-sqlite_fetch_and_increment-idx">sqlite_fetch_and_increment</span></a></li><li><a href="#record-and-attributes-uuid"><span id="record-and-attributes-uuid-idx">uuid</span></a></li></ul><a href="#string"><h2 id="string-idx">Cadena</h2></a><ul><li><a href="#string-ascii"><span id="string-ascii-idx">ascii</span></a></li><li><a href="#string-char"><span id="string-char-idx">char</span></a></li><li><a href="#string-concat"><span id="string-concat-idx">concat</span></a></li><li><a href="#string-format"><span id="string-format-idx">format</span></a></li><li><a href="#string-format_date"><span id="string-format_date-idx">format_date</span></a></li><li><a href="#string-format_number"><span id="string-format_number-idx">format_number</span></a></li><li><a href="#string-left"><span id="string-left-idx">left</span></a></li><li><a href="#string-length"><span id="string-length-idx">length</span></a></li><li><a href="#string-lower"><span id="string-lower-idx">lower</span></a></li><li><a href="#string-lpad"><span id="string-lpad-idx">lpad</span></a></li><li><a href="#string-regexp_match"><span id="string-regexp_match-idx">regexp_match</span></a></li><li><a href="#string-regexp_replace"><span id="string-regexp_replace-idx">regexp_replace</span></a></li><li><a href="#string-regexp_substr"><span id="string-regexp_substr-idx">regexp_substr</span></a></li><li><a href="#string-replace"><span id="string-replace-idx">replace</span></a></li><li><a href="#string-right"><span id="string-right-idx">right</span></a></li><li><a href="#string-rpad"><span id="string-rpad-idx">rpad</span></a></li><li><a href="#string-strpos"><span id="string-strpos-idx">strpos</span></a></li><li><a href="#string-substr"><span id="string-substr-idx">substr</span></a></li><li><a href="#string-title"><span id="string-title-idx">title</span></a></li><li><a href="#string-to_string"><span id="string-to_string-idx">to_string</span></a></li><li><a href="#string-trim"><span id="string-trim-idx">trim</span></a></li><li><a href="#string-upper"><span id="string-upper-idx">upper</span></a></li><li><a href="#string-wordwrap"><span id="string-wordwrap-idx">wordwrap</span></a></li></ul> |
|
<div id="aggregates" class="group"><h2><a href="#aggregates-idx">grupo agregados</a></h2> |
|
<div class="description"><p>Contiene funciones que agregan valores sobre capas y campos.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-aggregate"><a href="#aggregates-aggregate-idx"> |
|
función aggregate |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un valor agregado calculado usando objetos de otra capa. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
aggregate |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
, |
|
<span class="argument"> |
|
aggregate |
|
</span> |
|
, |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
][, |
|
<span class="argument"> |
|
concatenator |
|
</span> |
|
][, |
|
<span class="argument"> |
|
order_by |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
Una cadena que represente el nombre o la ID de una capa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
aggregate |
|
</td> |
|
<td> |
|
a string corresponding to the aggregate to calculate. Valid options are: |
|
<br/> |
|
<ul> |
|
<li> |
|
count |
|
</li> |
|
<li> |
|
count_distinct |
|
</li> |
|
<li> |
|
count_missing |
|
</li> |
|
<li> |
|
min |
|
</li> |
|
<li> |
|
max |
|
</li> |
|
<li> |
|
sum |
|
</li> |
|
<li> |
|
mean |
|
</li> |
|
<li> |
|
median |
|
</li> |
|
<li> |
|
stdev |
|
</li> |
|
<li> |
|
stdevsample |
|
</li> |
|
<li> |
|
range |
|
</li> |
|
<li> |
|
minority |
|
</li> |
|
<li> |
|
majority |
|
</li> |
|
<li> |
|
q1: first quartile |
|
</li> |
|
<li> |
|
q3: third quartile |
|
</li> |
|
<li> |
|
iqr: inter quartile range |
|
</li> |
|
<li> |
|
min_length: minimum string length |
|
</li> |
|
<li> |
|
max_length: maximum string length |
|
</li> |
|
<li> |
|
concatenate: join strings with a concatenator |
|
</li> |
|
<li> |
|
concatenate_unique: join unique strings with a concatenator |
|
</li> |
|
<li> |
|
collect: create an aggregated multipart geometry |
|
</li> |
|
<li> |
|
array_agg: create an array of aggregated values |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
sub expresión o nombre de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión de filtrado opcional para limitar los objetos usados para calcular el agregado. Los campos y geometrías son de los objetos de la capa unida. Se puede acceder al objeto de origen con la variable @parent. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
concatenator |
|
</td> |
|
<td> |
|
cadena opcional a usar para unir valores para el agregado 'concatenar' |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
order_by |
|
</td> |
|
<td> |
|
optional filter expression to order the features used for calculating the aggregate. Fields and geometry are from the features on the joined layer. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
aggregate(layer:='rail_stations',aggregate:='sum',expression:="passengers") |
|
</code> |
|
→ |
|
<code> |
|
suma de todos los valores del campo passengers de la capa rail_stations |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
aggregate('rail_stations','sum', "passengers"/7) |
|
</code> |
|
→ |
|
<code> |
|
calcula una media diaria de "passengers" dividiendo el campo "passengers" por 7 antes de sumar los valores |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
aggregate(layer:='rail_stations',aggregate:='sum',expression:="passengers",filter:="class">3) |
|
</code> |
|
→ |
|
<code> |
|
suma todos los valores del campo "passengers" de los objetos en los que el atributo "class" es mayor que 3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
aggregate(layer:='rail_stations',aggregate:='concatenate', expression:="name", concatenator:=',') |
|
</code> |
|
→ |
|
<code> |
|
lista separada por comas del campo name para todos los objetos de la capa rail_stations |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
aggregate(layer:='países', aggregate:='max', expression:="código", filter:=intersects( $geometry, geometry(@parent) ) ) |
|
</code> |
|
→ |
|
<code> |
|
El código del país de un país que intersecte en la capa 'países' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-array_agg"><a href="#aggregates-array_agg-idx"> |
|
función array_agg |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz de valores agregados a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_agg |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
][, |
|
<span class="argument"> |
|
order_by |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
order_by |
|
</td> |
|
<td> |
|
optional expression to use to order features used to calculate aggregate |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_agg("name",group_by:="state") |
|
</code> |
|
→ |
|
<code> |
|
lista de nombres, agrupados por campo de estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-collect"><a href="#aggregates-collect-idx"> |
|
función collect |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la geometría multiparte de geometrías agregadas a partir una expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
collect |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
expresión de geometría a agregar. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
collect( $geometry ) |
|
</code> |
|
→ |
|
<code> |
|
geometría multiparte de geometrías agregadas |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-concatenate"><a href="#aggregates-concatenate-idx"> |
|
función concatenate |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns all aggregated strings from a field or expression joined by a delimiter. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
concatenate |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
][, |
|
<span class="argument"> |
|
concatenator |
|
</span> |
|
][, |
|
<span class="argument"> |
|
order_by |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
concatenator |
|
</td> |
|
<td> |
|
cadena opcional a usar para unir valores |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
order_by |
|
</td> |
|
<td> |
|
optional expression to use to order features used to calculate aggregate |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
concatenar("nombre_ciudad",agrupar_por:="estado",concatenador:=',') |
|
</code> |
|
→ |
|
<code> |
|
lista separada por comas de nombres_ciudad, agrupados por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-concatenate_unique"><a href="#aggregates-concatenate_unique-idx"> |
|
función concatenate_unique |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns all unique strings from a field or expression joined by a delimiter. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
concatenate_unique |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
][, |
|
<span class="argument"> |
|
concatenator |
|
</span> |
|
][, |
|
<span class="argument"> |
|
order_by |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
concatenator |
|
</td> |
|
<td> |
|
cadena opcional a usar para unir valores |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
order_by |
|
</td> |
|
<td> |
|
optional expression to use to order features used to calculate aggregate |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
concatenar("nombre_ciudad",agrupar_por:="estado",concatenador:=',') |
|
</code> |
|
→ |
|
<code> |
|
comma separated list of unique town_names, grouped by state field |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-count"><a href="#aggregates-count-idx"> |
|
función count |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el recuento de objetos coincidentes. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
count |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
contar("estaciones",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
cuenta de estaciones, agrupados por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-count_distinct"><a href="#aggregates-count_distinct-idx"> |
|
función count_distinct |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el recuento de valores distintos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
count_distinct |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
contar_distintos("estaciones",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
cuenta de valores distintos de estaciones, agrupados por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-count_missing"><a href="#aggregates-count_missing-idx"> |
|
función count_missing |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el recuento de valores que faltan (nulo). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
count_missing |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
contar_faltantes("estaciones",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
cuenta de valores que faltan (nulos) de estaciones, agrupados por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-iqr"><a href="#aggregates-iqr-idx"> |
|
función iqr |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el rango de intercuartil calculado a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
iqr |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
iqr("population",group_by:="state") |
|
</code> |
|
→ |
|
<code> |
|
rango de intercuartil del valor de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-majority"><a href="#aggregates-majority-idx"> |
|
función majority |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la mayoría agregada de los valores (valores que aparecen de forma más común) de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
majority |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
mayoría("clase",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
valor de clase que ocurre con más frecuencia, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-max_length"><a href="#aggregates-max_length-idx"> |
|
función max_length |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la longitud máxima de cadenas a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
max_length |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
longitud_max("nombre_ciudad",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
longitud máxima de nombre_ciudad, agrupada por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-maximum"><a href="#aggregates-maximum-idx"> |
|
función maximum |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor máximo agregado a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
maximum |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
máximo("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
valor máximo de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-mean"><a href="#aggregates-mean-idx"> |
|
función mean |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor medio agregado a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
mean |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
media("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
valor medio de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-median"><a href="#aggregates-median-idx"> |
|
función median |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor de la mediana agregada a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
median |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
mediana("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
valor mediana de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-min_length"><a href="#aggregates-min_length-idx"> |
|
función min_length |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la longitud mínima de cadenas a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
min_length |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
longitud_min("nombre_ciudad",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
longitud mínima de nombre_ciudad, agrupada por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-minimum"><a href="#aggregates-minimum-idx"> |
|
función minimum |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor mínimo agregado a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
minimum |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
mínimo("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
valor mínimo de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-minority"><a href="#aggregates-minority-idx"> |
|
función minority |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la minoría agregada de valores (valor que ocurre con menos frecuencia) a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
minority |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
mayoría("clase",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
valor de clase que ocurre con menos frecuencia, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-q1"><a href="#aggregates-q1-idx"> |
|
función q1 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el primer cuartil calculado a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
q1 |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
q1("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
primer cuartil del valor de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-q3"><a href="#aggregates-q3-idx"> |
|
función q3 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el tercer cuartil calculado a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
q3 |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
q3("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
tercer cuartil del valor de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-range"><a href="#aggregates-range-idx"> |
|
función range |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el rango agregado de valores (máximo - mínimo) de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
range |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
rango("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
rango de valores de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-relation_aggregate"><a href="#aggregates-relation_aggregate-idx"> |
|
función relation_aggregate |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un valor agregado calculado usando todos los objetos hijos coincidentes de una relación de capas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
relation_aggregate |
|
</span> |
|
( |
|
<span class="argument"> |
|
relation |
|
</span> |
|
, |
|
<span class="argument"> |
|
aggregate |
|
</span> |
|
, |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
concatenator |
|
</span> |
|
][, |
|
<span class="argument"> |
|
order_by |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
relation |
|
</td> |
|
<td> |
|
una cadena que representa una ID de relación |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
aggregate |
|
</td> |
|
<td> |
|
a string corresponding to the aggregate to calculate. Valid options are: |
|
<br/> |
|
<ul> |
|
<li> |
|
count |
|
</li> |
|
<li> |
|
count_distinct |
|
</li> |
|
<li> |
|
count_missing |
|
</li> |
|
<li> |
|
min |
|
</li> |
|
<li> |
|
max |
|
</li> |
|
<li> |
|
sum |
|
</li> |
|
<li> |
|
mean |
|
</li> |
|
<li> |
|
median |
|
</li> |
|
<li> |
|
stdev |
|
</li> |
|
<li> |
|
stdevsample |
|
</li> |
|
<li> |
|
range |
|
</li> |
|
<li> |
|
minority |
|
</li> |
|
<li> |
|
majority |
|
</li> |
|
<li> |
|
q1: first quartile |
|
</li> |
|
<li> |
|
q3: third quartile |
|
</li> |
|
<li> |
|
iqr: inter quartile range |
|
</li> |
|
<li> |
|
min_length: minimum string length |
|
</li> |
|
<li> |
|
max_length: maximum string length |
|
</li> |
|
<li> |
|
concatenate: join strings with a concatenator |
|
</li> |
|
<li> |
|
concatenate_unique: join unique strings with a concatenator |
|
</li> |
|
<li> |
|
collect: create an aggregated multipart geometry |
|
</li> |
|
<li> |
|
array_agg: create an array of aggregated values |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
sub expresión o nombre de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
concatenator |
|
</td> |
|
<td> |
|
cadena opcional a usar para unir valores para el agregado 'concatenar' |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
order_by |
|
</td> |
|
<td> |
|
optional expression to order the features used for calculating the aggregate. Fields and geometry are from the features on the joined layer. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
relation_aggregate(relation:='my_relation',aggregate:='mean',expression:="passengers") |
|
</code> |
|
→ |
|
<code> |
|
valor medio de todos los objetos hijos coincidentes usando la relación 'mi_relación' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
relation_aggregate('my_relation','sum', "passengers"/7) |
|
</code> |
|
→ |
|
<code> |
|
suma del campo pasajeros dividido por 7 de todos los objetos hijos coincidentes usando la relación 'mi_relación' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
relation_aggregate('my_relation','concatenate', "towns", concatenator:=',') |
|
</code> |
|
→ |
|
<code> |
|
lista separada por coma del campo ciudades para todos los objetos hijos coincidentes usando la relación 'mi_relación' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
relation_aggregate('my_relation','array_agg', "id") |
|
</code> |
|
→ |
|
<code> |
|
array of the id field from all matching child features using the 'my_relation' relation |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-stdev"><a href="#aggregates-stdev-idx"> |
|
función stdev |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la desviación estándar agregada a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
stdev |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
desv_est("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
desviación estándar del valor de población, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="aggregates-sum"><a href="#aggregates-sum-idx"> |
|
función sum |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor sumado agregado a partir de un campo o expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
sum |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
group_by |
|
</span> |
|
][, |
|
<span class="argument"> |
|
filter |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
subexpresión de campo a agregar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
group_by |
|
</td> |
|
<td> |
|
expresión opcional a usar para agrupar cálculos de agregados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter |
|
</td> |
|
<td> |
|
expresión opcional a usar para filtrar objetos utilizados para calcular el agregado |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
suma("población",agrupar_por:="estado") |
|
</code> |
|
→ |
|
<code> |
|
valor de población sumado, agrupado por el campo estado |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="arrays" class="group"><h2><a href="#arrays-idx">grupo matrices</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones de expresiones para la creación y manipulación de matrices (también conocidas como estructuras de datos en lista). El orden de los valores dentro de la matriz importa, a diferencia de la estructura de datos de "mapa", en donde el orden de pares clave-valor es irrelevante y los valores se identifican por sus claves.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array"><a href="#arrays-array-idx"> |
|
función array |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz que contiene todos los valores pasados como parámetros. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array |
|
</span> |
|
( |
|
<span class="argument"> |
|
value1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
value2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un valor |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array(2,10) |
|
</code> |
|
→ |
|
<code> |
|
[ 2, 10 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_all"><a href="#arrays-array_all-idx"> |
|
función array_all |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if an array contains all the values of a given array. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_all |
|
</span> |
|
( |
|
<span class="argument"> |
|
array_a |
|
</span> |
|
, |
|
<span class="argument"> |
|
array_b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array_a |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
array_b |
|
</td> |
|
<td> |
|
the array of values to search |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_all(array(1,2,3),array(2,3)) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_all(array(1,2,3),array(1,2,4)) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_append"><a href="#arrays-array_append-idx"> |
|
función array_append |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz con el valor dado añadido al final. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_append |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
el valor a añadir |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_append(array(1,2,3),4) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 3, 4 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_cat"><a href="#arrays-array_cat-idx"> |
|
función array_cat |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz que contiene todas las matrices dadas concatenadas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_cat |
|
</span> |
|
( |
|
<span class="argument"> |
|
array1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
array2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_cat(array(1,2),array(2,3)) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 2, 3 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_contains"><a href="#arrays-array_contains-idx"> |
|
función array_contains |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve verdadero si una matriz contiene el valor dado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_contains |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
el valor a buscar |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_contains(array(1,2,3),2) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_distinct"><a href="#arrays-array_distinct-idx"> |
|
función array_distinct |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz que contiene los valores distintos de la matriz dada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_distinct |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_distinct(array(1,2,3,2,1)) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 3 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_filter"><a href="#arrays-array_filter-idx"> |
|
función array_filter |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz con sólo los ítems para los cuales la expresión evalúa a verdadero. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_filter |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
expression |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
an expression to evaluate on each item. The variable `@element` will be replaced by the current value. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_filter(array(1,2,3),@element < 3) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_find"><a href="#arrays-array_find-idx"> |
|
función array_find |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el índice de un valor dentro de una matriz (0 para el primero). Devuelve -1 si no se encuentra el valor. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_find |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
el valor a buscar |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_find(array(1,2,3),2) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_first"><a href="#arrays-array_first-idx"> |
|
función array_first |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el primer valor de una matriz. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_first |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_first(array('a','b','c')) |
|
</code> |
|
→ |
|
<code> |
|
'a' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_foreach"><a href="#arrays-array_foreach-idx"> |
|
función array_foreach |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns an array with the given expression evaluated on each item. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_foreach |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
expression |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
an expression to evaluate on each item. The variable `@element` will be replaced by the current value. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_foreach(array('a','b','c'),upper(@element)) |
|
</code> |
|
→ |
|
<code> |
|
[ 'A', 'B', 'C' ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_foreach(array(1,2,3),@element + 10) |
|
</code> |
|
→ |
|
<code> |
|
[ 11, 12, 13 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_get"><a href="#arrays-array_get-idx"> |
|
función array_get |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor N de una matriz (0 para el primero). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_get |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
index |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
index |
|
</td> |
|
<td> |
|
el índica a obtener (basado en 0) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_get(array('a','b','c'),1) |
|
</code> |
|
→ |
|
<code> |
|
'b' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_insert"><a href="#arrays-array_insert-idx"> |
|
función array_insert |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz con el valor dado añadido en la posición indicada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_insert |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
pos |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
pos |
|
</td> |
|
<td> |
|
la posición en la que añadir (basado en 0) |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
el valor a añadir |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_insert(array(1,2,3),1,100) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 100, 2, 3 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_intersect"><a href="#arrays-array_intersect-idx"> |
|
función array_intersect |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve verdadero si un elemento de la matriz1 está presente en la matriz2. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_intersect |
|
</span> |
|
( |
|
<span class="argument"> |
|
array1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
array2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array1 |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
array2 |
|
</td> |
|
<td> |
|
otra matriz |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_intersect(array(1,2,3,4),array(4,0,2,5)) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_last"><a href="#arrays-array_last-idx"> |
|
función array_last |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el último valor de una matriz. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_last |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_last(array('a','b','c')) |
|
</code> |
|
→ |
|
<code> |
|
'c' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_length"><a href="#arrays-array_length-idx"> |
|
función array_length |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el número de elementos de una matriz. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_length |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_length(array(1,2,3)) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_prepend"><a href="#arrays-array_prepend-idx"> |
|
función array_prepend |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz con el valor dado añadido al principio. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_prepend |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
el valor a añadir |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_prepend(array(1,2,3),0) |
|
</code> |
|
→ |
|
<code> |
|
[ 0, 1, 2, 3 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_remove_all"><a href="#arrays-array_remove_all-idx"> |
|
función array_remove_all |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz con todas las entradas del valor dado eliminadas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_remove_all |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
los valores a eliminar |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_remove_all(array('a','b','c','b'),'b') |
|
</code> |
|
→ |
|
<code> |
|
[ 'a', 'c' ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_remove_at"><a href="#arrays-array_remove_at-idx"> |
|
función array_remove_at |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz con el índice dado eliminado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_remove_at |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
pos |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
pos |
|
</td> |
|
<td> |
|
la posición a eliminar (basado en 0) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_remove_at(array(1,2,3),1) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 3 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_reverse"><a href="#arrays-array_reverse-idx"> |
|
función array_reverse |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la matriz dada con los valores de la matriz en orden inverso. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_reverse |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_reverse(array(2,4,0,10)) |
|
</code> |
|
→ |
|
<code> |
|
[ 10, 0, 4, 2 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_slice"><a href="#arrays-array_slice-idx"> |
|
función array_slice |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una porción de la matriz. El fragmento es definido por los argumentos start_pos y end_pos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_slice |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
, |
|
<span class="argument"> |
|
start_pos |
|
</span> |
|
, |
|
<span class="argument"> |
|
end_pos |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
start_pos |
|
</td> |
|
<td> |
|
el índice de la posición inicial del fragmento (basado en 0). El índice de start_pos se incluye en el fragmento. Si se usa una start_pos negativa, el índice se cuenta desde el final de la lista (basado en -1). |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
end_pos |
|
</td> |
|
<td> |
|
el índice de la posición final del fragmento (basado en 0). El índice de end_pos se incluye en el fragmento. Si se usa una end_pos negativa, el índice se cuenta desde el final de la lista (basado en -1). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_slice(array(1,2,3,4,5),0,3) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 3, 4 ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_slice(array(1,2,3,4,5),0,-1) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 3, 4, 5 ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_slice(array(1,2,3,4,5),-5,-1) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 3, 4, 5 ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_slice(array(1,2,3,4,5),0,0) |
|
</code> |
|
→ |
|
<code> |
|
[ 1 ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_slice(array(1,2,3,4,5),-2,-1) |
|
</code> |
|
→ |
|
<code> |
|
[ 4, 5 ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_slice(array(1,2,3,4,5),-1,-1) |
|
</code> |
|
→ |
|
<code> |
|
[ 5 ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_slice(array('Dufour','Valmiera','Chugiak','Brighton'),1,2) |
|
</code> |
|
→ |
|
<code> |
|
[ 'Valmiera', 'Chugiak' ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_slice(array_slice(array('Dufour','Valmiera','Chugiak','Brighton'),-2,-1) |
|
</code> |
|
→ |
|
<code> |
|
[ 'Chugiak', 'Brighton' ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_sort"><a href="#arrays-array_sort-idx"> |
|
función array_sort |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the provided array with its elements sorted. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_sort |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
[, |
|
<span class="argument"> |
|
ascending=true |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
una matriz |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
ascending |
|
</td> |
|
<td> |
|
set this parameter to false to sort the array in descending order |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_sort(array(3,2,1)) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 3 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-array_to_string"><a href="#arrays-array_to_string-idx"> |
|
función array_to_string |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Concatenates array elements into a string separated by a delimiter and using optional string for empty values. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
array_to_string |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
[, |
|
<span class="argument"> |
|
delimiter=',' |
|
</span> |
|
][, |
|
<span class="argument"> |
|
empty_value='' |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
la matriz de entrada |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
delimiter |
|
</td> |
|
<td> |
|
el delimitador de cadena utilizado para separa los elementos de la matriz concatenados |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
empty_value |
|
</td> |
|
<td> |
|
la cadena opcional usada como reemplazo para coincidencias vacías (longitud cero) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
array_to_string(array('1','2','3')) |
|
</code> |
|
→ |
|
<code> |
|
'1,2,3' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_to_string(array(1,2,3),'-') |
|
</code> |
|
→ |
|
<code> |
|
'1-2-3' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
array_to_string(array('1','','3'),',','0') |
|
</code> |
|
→ |
|
<code> |
|
'1,0,3' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-generate_series"><a href="#arrays-generate_series-idx"> |
|
función generate_series |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates an array containing a sequence of numbers. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
generate_series |
|
</span> |
|
( |
|
<span class="argument"> |
|
start |
|
</span> |
|
, |
|
<span class="argument"> |
|
stop |
|
</span> |
|
[, |
|
<span class="argument"> |
|
step=1 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
start |
|
</td> |
|
<td> |
|
first value of the sequence |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
stop |
|
</td> |
|
<td> |
|
value that ends the sequence once reached |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
step |
|
</td> |
|
<td> |
|
value used as the increment between values |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
generate_series(1,5) |
|
</code> |
|
→ |
|
<code> |
|
[ 1, 2, 3, 4, 5 ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
generate_series(5,1,-1) |
|
</code> |
|
→ |
|
<code> |
|
[ 5, 4, 3, 2, 1 ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-regexp_matches"><a href="#arrays-regexp_matches-idx"> |
|
función regexp_matches |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una matriz de todas las cadenas capturadas por grupos de captura, en el orden en el que los propios grupos aparecen en la expresión regular proporcionada contra la cadena. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
regexp_matches |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
, |
|
<span class="argument"> |
|
regex |
|
</span> |
|
[, |
|
<span class="argument"> |
|
empty_value='' |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
la cadena para capturar grupos desde la expresión regular |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
regex |
|
</td> |
|
<td> |
|
la expresión regular usada para capturar grupos |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
empty_value |
|
</td> |
|
<td> |
|
la cadena opcional usada como reemplazo para coincidencias vacías (longitud cero) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
regexp_matches('QGIS=>rocks','(.*)=>(.*)') |
|
</code> |
|
→ |
|
<code> |
|
[ 'QGIS', 'rocks' ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
regexp_matches('key=>','(.*)=>(.*)','empty value') |
|
</code> |
|
→ |
|
<code> |
|
[ 'key', 'empty value' ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="arrays-string_to_array"><a href="#arrays-string_to_array-idx"> |
|
función string_to_array |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Divide una cadena en una matriz usando el delimitador proporcionado y una cadena opcional para valores vacíos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
string_to_array |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
[, |
|
<span class="argument"> |
|
delimiter=',' |
|
</span> |
|
][, |
|
<span class="argument"> |
|
empty_value='' |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
la cadena de entrada |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
delimiter |
|
</td> |
|
<td> |
|
el delimitador de cadena utilizado para dividir la cadena de entrada |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
empty_value |
|
</td> |
|
<td> |
|
la cadena opcional usada como reemplazo para coincidencias vacías (longitud cero) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
string_to_array('1,2,3',',') |
|
</code> |
|
→ |
|
<code> |
|
[ '1', '2', '3' ] |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
string_to_array('1,,3',',','0') |
|
</code> |
|
→ |
|
<code> |
|
[ '1', '0', '3' ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="color" class="group"><h2><a href="#color-idx">grupo color</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones para manipular colores</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_cmyk"><a href="#color-color_cmyk-idx"> |
|
función color_cmyk |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus componentes cian, magenta, amarillo y negro |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_cmyk |
|
</span> |
|
( |
|
<span class="argument"> |
|
cyan |
|
</span> |
|
, |
|
<span class="argument"> |
|
magenta |
|
</span> |
|
, |
|
<span class="argument"> |
|
yellow |
|
</span> |
|
, |
|
<span class="argument"> |
|
black |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
cyan |
|
</td> |
|
<td> |
|
componente cian del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
magenta |
|
</td> |
|
<td> |
|
componente magenta del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
yellow |
|
</td> |
|
<td> |
|
componente amarillo del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
black |
|
</td> |
|
<td> |
|
componente negro del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_cmyk(100,50,0,10) |
|
</code> |
|
→ |
|
<code> |
|
0,115,230 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_cmyka"><a href="#color-color_cmyka-idx"> |
|
función color_cmyka |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus componentes cian, magenta, amarillo, negro y alfa (transparencia) |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_cmyka |
|
</span> |
|
( |
|
<span class="argument"> |
|
cyan |
|
</span> |
|
, |
|
<span class="argument"> |
|
magenta |
|
</span> |
|
, |
|
<span class="argument"> |
|
yellow |
|
</span> |
|
, |
|
<span class="argument"> |
|
black |
|
</span> |
|
, |
|
<span class="argument"> |
|
alpha |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
cyan |
|
</td> |
|
<td> |
|
componente cian del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
magenta |
|
</td> |
|
<td> |
|
componente magenta del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
yellow |
|
</td> |
|
<td> |
|
componente amarillo del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
black |
|
</td> |
|
<td> |
|
componente negro del color, como un valor entero de porcentaje de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
alpha |
|
</td> |
|
<td> |
|
componente alfa como un valor entero de 0 (completamente transparente) a 255 (opaco). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_cmyk(100,50,0,10,200) |
|
</code> |
|
→ |
|
<code> |
|
0,115,230,200 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_grayscale_average"><a href="#color-color_grayscale_average-idx"> |
|
función color_grayscale_average |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Applies a grayscale filter and returns a string representation from a provided color. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_grayscale_average |
|
</span> |
|
( |
|
<span class="argument"> |
|
color |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
color |
|
</td> |
|
<td> |
|
una cadena de color |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_grayscale_average('255,100,50') |
|
</code> |
|
→ |
|
<code> |
|
127,127,127,255 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_hsl"><a href="#color-color_hsl-idx"> |
|
función color_hsl |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus atributos de matiz, saturación y luminosidad. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_hsl |
|
</span> |
|
( |
|
<span class="argument"> |
|
hue |
|
</span> |
|
, |
|
<span class="argument"> |
|
saturation |
|
</span> |
|
, |
|
<span class="argument"> |
|
lightness |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
hue |
|
</td> |
|
<td> |
|
matiz de un color, como un entero de 0 a 360 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
saturation |
|
</td> |
|
<td> |
|
porcentaje de saturación del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
lightness |
|
</td> |
|
<td> |
|
porcentaje de luminosidad del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_hsl(100,50,70) |
|
</code> |
|
→ |
|
<code> |
|
166,217,140 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_hsla"><a href="#color-color_hsla-idx"> |
|
función color_hsla |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus atributos de matiz, saturación, luminosidad y canal alfa (transparencia). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_hsla |
|
</span> |
|
( |
|
<span class="argument"> |
|
hue |
|
</span> |
|
, |
|
<span class="argument"> |
|
saturation |
|
</span> |
|
, |
|
<span class="argument"> |
|
lightness |
|
</span> |
|
, |
|
<span class="argument"> |
|
alpha |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
hue |
|
</td> |
|
<td> |
|
matiz de un color, como un entero de 0 a 360 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
saturation |
|
</td> |
|
<td> |
|
porcentaje de saturación del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
lightness |
|
</td> |
|
<td> |
|
porcentaje de luminosidad del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
alpha |
|
</td> |
|
<td> |
|
componente alfa como un valor entero de 0 (completamente transparente) a 255 (opaco). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_hsla(100,50,70,200) |
|
</code> |
|
→ |
|
<code> |
|
166,217,140,200 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_hsv"><a href="#color-color_hsv-idx"> |
|
función color_hsv |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus atributos de matiz, saturación y valor. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_hsv |
|
</span> |
|
( |
|
<span class="argument"> |
|
hue |
|
</span> |
|
, |
|
<span class="argument"> |
|
saturation |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
hue |
|
</td> |
|
<td> |
|
matiz de un color, como un entero de 0 a 360 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
saturation |
|
</td> |
|
<td> |
|
porcentaje de saturación del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
porcentaje de valor del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_hsv(40,100,100) |
|
</code> |
|
→ |
|
<code> |
|
255,170,0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_hsva"><a href="#color-color_hsva-idx"> |
|
función color_hsva |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus atributos de matiz, saturación, valor y canal alfa (transparencia). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_hsva |
|
</span> |
|
( |
|
<span class="argument"> |
|
hue |
|
</span> |
|
, |
|
<span class="argument"> |
|
saturation |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
, |
|
<span class="argument"> |
|
alpha |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
hue |
|
</td> |
|
<td> |
|
matiz de un color, como un entero de 0 a 360 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
saturation |
|
</td> |
|
<td> |
|
porcentaje de saturación del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
porcentaje de valor del color, como un valor entero de 0 a 100 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
alpha |
|
</td> |
|
<td> |
|
componente alfa como un valor entero de 0 (completamente transparente) a 255 (opaco) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_hsva(40,100,100,200) |
|
</code> |
|
→ |
|
<code> |
|
255,170,0,200 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_mix_rgb"><a href="#color-color_mix_rgb-idx"> |
|
función color_mix_rgb |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a string representing a color mixing the red, green, blue, and alpha values of two provided colors based on a given ratio. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_mix_rgb |
|
</span> |
|
( |
|
<span class="argument"> |
|
color1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
color2 |
|
</span> |
|
, |
|
<span class="argument"> |
|
ratio |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
color1 |
|
</td> |
|
<td> |
|
una cadena de color |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
color2 |
|
</td> |
|
<td> |
|
una cadena de color |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
ratio |
|
</td> |
|
<td> |
|
una relación |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_mix_rgb('0,0,0','255,255,255',0.5) |
|
</code> |
|
→ |
|
<code> |
|
127,127,127,255 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_part"><a href="#color-color_part-idx"> |
|
función color_part |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un componente específico de una cadena de color, por ejemplo el componente rojo o el alfa. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_part |
|
</span> |
|
( |
|
<span class="argument"> |
|
color |
|
</span> |
|
, |
|
<span class="argument"> |
|
component |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
color |
|
</td> |
|
<td> |
|
una cadena de color |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
component |
|
</td> |
|
<td> |
|
una cadena que corresponde al componente del color a devolver. Las opciones válidas son: |
|
<br/> |
|
<ul> |
|
<li> |
|
red: componente rojo RGB (0-255) |
|
</li> |
|
<li> |
|
green: componente verde RGB (0-255) |
|
</li> |
|
<li> |
|
blue: componente azul RGB (0-255) |
|
</li> |
|
<li> |
|
alpha: valor alfa (transparencia) (0-255) |
|
</li> |
|
<li> |
|
hue: matiz HSV (0-360) |
|
</li> |
|
<li> |
|
saturation: saturación HSV (0-100) |
|
</li> |
|
<li> |
|
value: valor HSV (0-100) |
|
</li> |
|
<li> |
|
hsl_hue: matiz HSL (0-360) |
|
</li> |
|
<li> |
|
hsl_saturation: saturación HSL (0-100) |
|
</li> |
|
<li> |
|
lightness: luminosidad HSL (0-100) |
|
</li> |
|
<li> |
|
cyan: componente cian CMYK (0-100) |
|
</li> |
|
<li> |
|
magenta: componente magenta CMYK (0-100) |
|
</li> |
|
<li> |
|
yellow: componente amarillo CMYK (0-100) |
|
</li> |
|
<li> |
|
black: componente negro CMYK (0-100) |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_part('200,10,30','green') |
|
</code> |
|
→ |
|
<code> |
|
10 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_rgb"><a href="#color-color_rgb-idx"> |
|
función color_rgb |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus componentes rojo, verde y azul. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_rgb |
|
</span> |
|
( |
|
<span class="argument"> |
|
red |
|
</span> |
|
, |
|
<span class="argument"> |
|
green |
|
</span> |
|
, |
|
<span class="argument"> |
|
blue |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
red |
|
</td> |
|
<td> |
|
componente rojo del color, como un valor entero de 0 a 255 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
green |
|
</td> |
|
<td> |
|
componente verde del color, como un valor entero de 0 a 255 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
blue |
|
</td> |
|
<td> |
|
componente azul del color, como un valor entero de 0 a 255 |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_rgb(255,127,0) |
|
</code> |
|
→ |
|
<code> |
|
255,127,0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-color_rgba"><a href="#color-color_rgba-idx"> |
|
función color_rgba |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación en forma de cadena de un color en base a sus componentes rojo, verde, azul y alfa (transparencia). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
color_rgba |
|
</span> |
|
( |
|
<span class="argument"> |
|
red |
|
</span> |
|
, |
|
<span class="argument"> |
|
green |
|
</span> |
|
, |
|
<span class="argument"> |
|
blue |
|
</span> |
|
, |
|
<span class="argument"> |
|
alpha |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
red |
|
</td> |
|
<td> |
|
componente rojo del color, como un valor entero de 0 a 255 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
green |
|
</td> |
|
<td> |
|
componente verde del color, como un valor entero de 0 a 255 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
blue |
|
</td> |
|
<td> |
|
componente azul del color, como un valor entero de 0 a 255 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
alpha |
|
</td> |
|
<td> |
|
componente alfa como un valor entero de 0 (completamente transparente) a 255 (opaco). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
color_rgba(255,127,0,200) |
|
</code> |
|
→ |
|
<code> |
|
255,127,0,200 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-create_ramp"><a href="#color-create_ramp-idx"> |
|
función create_ramp |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una rampa de gradiente de un mapa de colores y pasos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
create_ramp |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
[, |
|
<span class="argument"> |
|
discrete |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
a map of color strings and steps |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
discrete |
|
</td> |
|
<td> |
|
declarar si la rampa de color es discreta |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
ramp_color(create_array(map(0,'0,0,0',1,'255,0,0')),1) |
|
</code> |
|
→ |
|
<code> |
|
'255,0,0,255' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-darker"><a href="#color-darker-idx"> |
|
función darker |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una cadena de color más oscura (o más clara) |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
darker |
|
</span> |
|
( |
|
<span class="argument"> |
|
color |
|
</span> |
|
, |
|
<span class="argument"> |
|
factor |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
color |
|
</td> |
|
<td> |
|
una cadena de color |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
factor |
|
</td> |
|
<td> |
|
un número entero que corresponde al factor de oscurecimiento: |
|
<ul> |
|
<li> |
|
Si el factor es mayor de 100, esta función devuelve un color más oscuro (por ej., establecer el factor a 300 devuelve un color que tiene un tercio de brillo); |
|
</li> |
|
<li> |
|
Si el factor es menor que 100, el color devuelto es más claro, pero se recomienda usar la función lighter() para este propósito; |
|
</li> |
|
<li> |
|
Si el factor es 0 o negativo, el valor devuelto es inespecífico. |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
darker('200,10,30',300) |
|
</code> |
|
→ |
|
<code> |
|
'66,3,10,255' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-lighter"><a href="#color-lighter-idx"> |
|
función lighter |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una cadena de color más clara (o más oscura) |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
lighter |
|
</span> |
|
( |
|
<span class="argument"> |
|
color |
|
</span> |
|
, |
|
<span class="argument"> |
|
factor |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
color |
|
</td> |
|
<td> |
|
una cadena de color |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
factor |
|
</td> |
|
<td> |
|
un número entero que corresponde al factor de aclarado: |
|
<ul> |
|
<li> |
|
Si el factor es mayor de 100, esta función devuelve un color más claro (por ej., establecer el factor a 150 devuelve un color que es un 50% más brillante); |
|
</li> |
|
<li> |
|
Si el factor es menor que 100, el color devuelto es más oscuro, pero se recomienda usar la función darker() para este propósito; |
|
</li> |
|
<li> |
|
Si el factor es 0 o negativo, el valor devuelto es inespecífico. |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
lighter('200,10,30',200) |
|
</code> |
|
→ |
|
<code> |
|
'255,158,168,255' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-project_color"><a href="#color-project_color-idx"> |
|
función project_color |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un color del esquema de color del proyecto. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
project_color |
|
</span> |
|
( |
|
<span class="argument"> |
|
name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
name |
|
</td> |
|
<td> |
|
el nombre de un color |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
project_color('Logo color') |
|
</code> |
|
→ |
|
<code> |
|
20,140,50 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-ramp_color"><a href="#color-ramp_color-idx"> |
|
función ramp_color |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una cadena que representa un color de una rampa de color. |
|
</p> |
|
</div> |
|
<h3 id="color-ramp_color"><a href="#color-ramp_color-idx"> |
|
Variante de rampa guardada |
|
</a></h3> |
|
<div class="description"> |
|
Devuelve una cadena que representa un color de una rampa guardada |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
ramp_color |
|
</span> |
|
( |
|
<span class="argument"> |
|
ramp_name |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
ramp_name |
|
</td> |
|
<td> |
|
el nombre de la rampa de color como una cadena, por ejemplo 'Spectral' |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
la posición en la rampa de la que seleccionar el color, como un número real entre 0 y 1 |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
ramp_color('Spectral',0.3) |
|
</code> |
|
→ |
|
<code> |
|
'253,190,115,255' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h4> |
|
Notas |
|
</h4> |
|
<div class="notes"> |
|
<p> |
|
Las rampas de color disponibles varían entre instalaciones de QGIS. Esta función puede no dar el resultado esperado su mueve su proyecto de QGIS entre instalaciones. |
|
</p> |
|
</div> |
|
<h3 id="color-ramp_color"><a href="#color-ramp_color-idx"> |
|
Variante de rampa creada por expresión |
|
</a></h3> |
|
<div class="description"> |
|
Devuelve una cadena que representa un color de una rampa creada por expresión |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
ramp_color |
|
</span> |
|
( |
|
<span class="argument"> |
|
ramp |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
ramp |
|
</td> |
|
<td> |
|
la rampa de color |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
la posición en la rampa de la que seleccionar el color, como un número real entre 0 y 1 |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
ramp_color(create_ramp(map(0,'0,0,0',1,'255,0,0')),1) |
|
</code> |
|
→ |
|
<code> |
|
'255,0,0,255' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="color-set_color_part"><a href="#color-set_color_part-idx"> |
|
función set_color_part |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Establece el componente de un color específico para la cadena de un color, por ejemplo el componente rojo o el alfa. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
set_color_part |
|
</span> |
|
( |
|
<span class="argument"> |
|
color |
|
</span> |
|
, |
|
<span class="argument"> |
|
component |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
color |
|
</td> |
|
<td> |
|
una cadena de color |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
component |
|
</td> |
|
<td> |
|
una cadena que corresponde al componente del color a establecer. Las opciones válidas son: |
|
<br/> |
|
<ul> |
|
<li> |
|
red: componente rojo RGB (0-255) |
|
</li> |
|
<li> |
|
green: componente verde RGB (0-255) |
|
</li> |
|
<li> |
|
blue: componente azul RGB (0-255) |
|
</li> |
|
<li> |
|
alpha: valor alfa (transparencia) (0-255) |
|
</li> |
|
<li> |
|
hue: matiz HSV (0-360) |
|
</li> |
|
<li> |
|
saturation: saturación HSV (0-100) |
|
</li> |
|
<li> |
|
value: valor HSV (0-100) |
|
</li> |
|
<li> |
|
hsl_hue: matiz HSL (0-360) |
|
</li> |
|
<li> |
|
hsl_saturation: saturación HSL (0-100) |
|
</li> |
|
<li> |
|
lightness: luminosidad HSL (0-100) |
|
</li> |
|
<li> |
|
cyan: componente cian CMYK (0-100) |
|
</li> |
|
<li> |
|
magenta: componente magenta CMYK (0-100) |
|
</li> |
|
<li> |
|
yellow: componente amarillo CMYK (0-100) |
|
</li> |
|
<li> |
|
black: componente negro CMYK (0-100) |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
valor nuevo para el componente de color, restetando los rangos listados arriba |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
set_color_part('200,10,30','green',50) |
|
</code> |
|
→ |
|
<code> |
|
200,50,30 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="conditionals" class="group"><h2><a href="#conditionals-idx">grupo condicionales</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones para realizar comprobaciones condicionales en expresiones.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conditionals-coalesce"><a href="#conditionals-coalesce-idx"> |
|
función coalesce |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el primer valor no-NULO de la lista de expresiones |
|
<br/> |
|
Esta función puede tomar cualquier número de argumentos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
coalesce |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
expression2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
cualquier expresión o valor válidos, sin importar el tipo. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
coalesce(NULO, 2) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
coalesce(NULO, 2, 3) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
coalesce(7, NULO, 3*2) |
|
</code> |
|
→ |
|
<code> |
|
7 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
coalesce("campoA", "fallbackField", 'ERROR') |
|
</code> |
|
→ |
|
<code> |
|
el valor del campoA si no es NULO, de lo contrario el valor de "fallbackField" o la cadena 'ERROR' si ambos son NULO |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conditionals-if"><a href="#conditionals-if-idx"> |
|
función if |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Prueba una condición y devuelve un resultado diferente dependiendo de la comprobación condicional. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
if |
|
</span> |
|
( |
|
<span class="argument"> |
|
condition |
|
</span> |
|
, |
|
<span class="argument"> |
|
result_when_true |
|
</span> |
|
, |
|
<span class="argument"> |
|
result_when_false |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
condition |
|
</td> |
|
<td> |
|
la condición que se debe evaluar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
result_when_true |
|
</td> |
|
<td> |
|
el resultado que se devolverá cuando la condición sea verdadera u otro valor que no convierta a falso. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
result_when_false |
|
</td> |
|
<td> |
|
el resultado que se devolverá cuando la condición sea falsa u otro valor que convierta a falso como 0 o ". NULO también se convertirá a falso. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
if( 1+1=2, 'Yes', 'No' ) |
|
</code> |
|
→ |
|
<code> |
|
'Sí' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
if( 1+1=3, 'Yes', 'No' ) |
|
</code> |
|
→ |
|
<code> |
|
'No' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
if( 5 > 3, 1, 0) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
if( '', 'It is true (not empty)', 'It is false (empty)' ) |
|
</code> |
|
→ |
|
<code> |
|
'It is false (empty)' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
if( ' ', 'It is true (not empty)', 'It is false (empty)' ) |
|
</code> |
|
→ |
|
<code> |
|
'It is true (not empty)' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
if( 0, 'One', 'Zero' ) |
|
</code> |
|
→ |
|
<code> |
|
'Cero' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
if( 10, 'One', 'Zero' ) |
|
</code> |
|
→ |
|
<code> |
|
'Uno' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conditionals-nullif"><a href="#conditionals-nullif-idx"> |
|
función nullif |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a null value if value1 equals value2; otherwise it returns value1. This can be used to conditionally substitute values with NULL. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
nullif |
|
</span> |
|
( |
|
<span class="argument"> |
|
value1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
value2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value1 |
|
</td> |
|
<td> |
|
The value that should either be used or substituted with NULL. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value2 |
|
</td> |
|
<td> |
|
The control value that will trigger the NULL substitution. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
nullif('(none)', '(none)') |
|
</code> |
|
→ |
|
<code> |
|
NULO |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
nullif('text', '(none)') |
|
</code> |
|
→ |
|
<code> |
|
'text' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
nullif("name", '') |
|
</code> |
|
→ |
|
<code> |
|
NULL, if name is an empty string (or already NULL), the name in any other case. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conditionals-regexp_match"><a href="#conditionals-regexp_match-idx"> |
|
función regexp_match |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la primera posición que coincide con una expresión regular dentro de una cadena o 0 si no se encuentra la subcadena. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
regexp_match |
|
</span> |
|
( |
|
<span class="argument"> |
|
input_string |
|
</span> |
|
, |
|
<span class="argument"> |
|
regex |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
input_string |
|
</td> |
|
<td> |
|
La cadena a probar frente a la expresión regular |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
regex |
|
</td> |
|
<td> |
|
La expresión regular frente a la que probar. El carácter barra invertida se debe escapar doblemente (ej.: "\\s" para capturar un carácter espacio en blanco). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
regexp_match('QGIS ROCKS','\\sROCKS') |
|
</code> |
|
→ |
|
<code> |
|
4 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conditionals-try"><a href="#conditionals-try-idx"> |
|
función try |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Intenta ejecutar una expresión y devuelve su valor si está libre de error. Si la expresión devuelve un error, se regresará un valor alternativo cuando se proporcione, de otro modo devolverá nulo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
try |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
[, |
|
<span class="argument"> |
|
alternative |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
la expresión que debe utilizarse |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
alternative |
|
</td> |
|
<td> |
|
el resultado que será devuelto si la expresión regresa un error. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
try( to_int( '1' ), 0 ) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
try( to_int( 'a' ), 0 ) |
|
</code> |
|
→ |
|
<code> |
|
0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
try( to_date( 'invalid_date' ) ) |
|
</code> |
|
→ |
|
<code> |
|
NULO |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="conversions" class="group"><h2><a href="#conversions-idx">grupo conversiones</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones para convertir unos tipos de datos en otros, por ejemplo cadena a entero o entero a cadena.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-from_base64"><a href="#conversions-from_base64-idx"> |
|
función from_base64 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Decodes a string in the Base64 encoding into a binary value. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
from_base64 |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
the string to decode |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
from_base64('UUdJUw==') |
|
</code> |
|
→ |
|
<code> |
|
'QGIS' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-hash"><a href="#conversions-hash-idx"> |
|
función hash |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a hash from a string with a given method. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
hash |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
, |
|
<span class="argument"> |
|
method |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
the string to hash |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
method |
|
</td> |
|
<td> |
|
The hash method among 'md4', 'md5', 'sha1', 'sha224', 'sha384', 'sha512', 'sha3_224', 'sha3_256', 'sha3_384', 'sha3_512', 'keccak_224', 'keccak_256', 'keccak_384', 'keccak_512' |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
hash('QGIS', md4) |
|
</code> |
|
→ |
|
<code> |
|
'c0fc71c241cdebb6e888cbac0e2b68eb' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', md5) |
|
</code> |
|
→ |
|
<code> |
|
'57470aaa9e22adaefac7f5f342f1c6da' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha1) |
|
</code> |
|
→ |
|
<code> |
|
'f87cfb2b74cdd5867db913237024e7001e62b114' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha224) |
|
</code> |
|
→ |
|
<code> |
|
'4093a619ada631c770f44bc643ead18fb393b93d6a6af1861fcfece0' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha256) |
|
</code> |
|
→ |
|
<code> |
|
'eb045cba7a797aaa06ac58830846e40c8e8c780bc0676d3393605fae50c05309' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha384) |
|
</code> |
|
→ |
|
<code> |
|
'91c1de038cc3d09fdd512e99f9dd9922efadc39ed21d3922e69a4305cc25506033aee388e554b78714c8734f9cd7e610' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha512) |
|
</code> |
|
→ |
|
<code> |
|
'c2c092f2ab743bf8edbeb6d028a745f30fc720408465ed369421f0a4e20fa5e27f0c90ad72d3f1d836eaa5d25cd39897d4cf77e19984668ef58da6e3159f18ac' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha3_224) |
|
</code> |
|
→ |
|
<code> |
|
'467f49a5039e7280d5d42fd433e80d203439e338eaabd701f0d6c17d' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha3_256) |
|
</code> |
|
→ |
|
<code> |
|
'540f7354b6b8a6e735f2845250f15f4f3ba4f666c55574d9e9354575de0e980f' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha3_384) |
|
</code> |
|
→ |
|
<code> |
|
'96052da1e77679e9a65f60d7ead961b287977823144786386eb43647b0901fd8516fa6f1b9d243fb3f28775e6dde6107' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', sha3_512) |
|
</code> |
|
→ |
|
<code> |
|
'900d079dc69761da113980253aa8ac0414a8bd6d09879a916228f8743707c4758051c98445d6b8945ec854ff90655005e02aceb0a2ffc6a0ebf818745d665349' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', keccak_224) |
|
</code> |
|
→ |
|
<code> |
|
'5b0ce6acef8b0a121d4ac4f3eaa8503c799ad4e26a3392d1fb201478' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', keccak_256) |
|
</code> |
|
→ |
|
<code> |
|
'991c520aa6815392de24087f61b2ae0fd56abbfeee4a8ca019c1011d327c577e' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hash('QGIS', keccak_384) |
|
</code> |
|
→ |
|
<code> |
|
'c57a3aed9d856fa04e5eeee9b62b6e027cca81ba574116d3cc1f0d48a1ef9e5886ff463ea8d0fac772ee473bf92f810d' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
keccak_512('QGIS') |
|
</code> |
|
→ |
|
<code> |
|
'6f0f751776b505e317de222508fa5d3ed7099d8f07c74fed54ccee6e7cdc6b89b4a085e309f2ee5210c9' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-md5"><a href="#conversions-md5-idx"> |
|
función md5 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a md5 hash from a string. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
md5 |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
the string to hash |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
md5('QGIS') |
|
</code> |
|
→ |
|
<code> |
|
'57470aaa9e22adaefac7f5f342f1c6da' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-sha256"><a href="#conversions-sha256-idx"> |
|
función sha256 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a sha256 hash from a string. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
sha256 |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
the string to hash |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
sha256('QGIS') |
|
</code> |
|
→ |
|
<code> |
|
'eb045cba7a797aaa06ac58830846e40c8e8c780bc0676d3393605fae50c05309' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_base64"><a href="#conversions-to_base64-idx"> |
|
función to_base64 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Encodes a binary value into a string, using the Base64 encoding. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_base64 |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
the binary value to encode |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_base64('QGIS') |
|
</code> |
|
→ |
|
<code> |
|
'UUdJUw==' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_date"><a href="#conversions-to_date-idx"> |
|
función to_date |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte una cadena de caracteres en un objeto fecha. Una cadena opcional de formato puede proporcionarse para formatear la cadena; ver |
|
<a href="https://doc.qt.io/qt-5/qdate.html#fromString-1"> |
|
QDate::fromString |
|
</a> |
|
para documentación adicional sobre el formato. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_date |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
[, |
|
<span class="argument"> |
|
format |
|
</span> |
|
][, |
|
<span class="argument"> |
|
language |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena que representa un valor de fecha |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
format |
|
</td> |
|
<td> |
|
format used to convert the string into a date |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
language |
|
</td> |
|
<td> |
|
idioma (minúsculas, dos- o tres-letras, código de idioma ISO 639) usado para convertir la cadena a fecha |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_date('2012-05-04') |
|
</code> |
|
→ |
|
<code> |
|
2012-05-04 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_date('June 29, 2019','MMMM d, yyyy') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_date('29 juin, 2019','d MMMM, yyyy','fr') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_datetime"><a href="#conversions-to_datetime-idx"> |
|
función to_datetime |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte una cadena de caracteres en un objeto fecha-hora. Una cadena opcional de formato puede proporcionarse para formatear la cadena; ver |
|
<a href="https://doc.qt.io/qt-5/qdatetime.html#fromString-1"> |
|
QDate::fromString |
|
</a> |
|
para documentación adicional sobre el formato. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_datetime |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
[, |
|
<span class="argument"> |
|
format |
|
</span> |
|
][, |
|
<span class="argument"> |
|
language |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena que representa un valor de fecha y hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
format |
|
</td> |
|
<td> |
|
formato usado para convertir la cadena a fecha-hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
language |
|
</td> |
|
<td> |
|
idioma (minúsculas, dos- o tres-letras, código de idioma ISO 639) usado para convertir la cadena a fecha-hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_datetime('2012-05-04 12:50:00') |
|
</code> |
|
→ |
|
<code> |
|
2012-05-04T12:50:00 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_datetime('June 29, 2019 @ 12:34','MMMM d, yyyy @ HH:mm') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29T12:34 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_datetime('29 juin, 2019 @ 12:34','d MMMM, yyyy @ HH:mm','fr') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29T12:34 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_dm"><a href="#conversions-to_dm-idx"> |
|
función to_dm |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convertir una coordenada a grados, minutos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_dm |
|
</span> |
|
( |
|
<span class="argument"> |
|
coordinate |
|
</span> |
|
, |
|
<span class="argument"> |
|
axis |
|
</span> |
|
, |
|
<span class="argument"> |
|
precision |
|
</span> |
|
[, |
|
<span class="argument"> |
|
formatting |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
coordinate |
|
</td> |
|
<td> |
|
Un valor de latitud o longitud. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
axis |
|
</td> |
|
<td> |
|
El eje de la coordenada. Ya sea 'x' o 'y'. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
precision |
|
</td> |
|
<td> |
|
Número de decimales. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
formatting |
|
</td> |
|
<td> |
|
Designa el tipo de formato. Valores aceptables son NULL, 'aligned' o 'suffix'. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_dm(6.3545681, 'x', 3) |
|
</code> |
|
→ |
|
<code> |
|
6°21.274′ |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_dm(6.3545681, 'y', 4, 'suffix') |
|
</code> |
|
→ |
|
<code> |
|
6°21.2741′N |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_dms"><a href="#conversions-to_dms-idx"> |
|
función to_dms |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convertir una coordenada a grados, minutos, segundos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_dms |
|
</span> |
|
( |
|
<span class="argument"> |
|
coordinate |
|
</span> |
|
, |
|
<span class="argument"> |
|
axis |
|
</span> |
|
, |
|
<span class="argument"> |
|
precision |
|
</span> |
|
[, |
|
<span class="argument"> |
|
formatting |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
coordinate |
|
</td> |
|
<td> |
|
Un valor de latitud o longitud. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
axis |
|
</td> |
|
<td> |
|
El eje de la coordenada. Ya sea 'x' o 'y'. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
precision |
|
</td> |
|
<td> |
|
Número de decimales. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
formatting |
|
</td> |
|
<td> |
|
Designa el tipo de formato. Valores aceptables son NULL, 'aligned' o 'suffix'. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_dms(6.3545681, 'x', 3) |
|
</code> |
|
→ |
|
<code> |
|
6°21′16.445″ |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_dms(6.3545681, 'y', 4, 'suffix') |
|
</code> |
|
→ |
|
<code> |
|
6°21′16.4452″N |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_int"><a href="#conversions-to_int-idx"> |
|
función to_int |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte una cadena a número entero. No devuelve nada si un valor no se puede convertir a entero (ej.: '123asd' no es válido). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_int |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena a convertir a número entero |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_int('123') |
|
</code> |
|
→ |
|
<code> |
|
123 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_interval"><a href="#conversions-to_interval-idx"> |
|
función to_interval |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Converts a string to a interval type. Can be used to take days, hours, month, etc of a date. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_interval |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
una cadena que representa un intervalo. Los formatos permitidos incluyen {n} días {n} horas {n} meses. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_datetime('2012-05-05 12:00:00') - to_interval('1 día 2 horas') |
|
</code> |
|
→ |
|
<code> |
|
2012-05-04T10:00:00 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_real"><a href="#conversions-to_real-idx"> |
|
función to_real |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte una cadena a número real. No devuelve nada si un valor no se puede convertir a real (ej.: '123.56asd' no es válido). Los números se redondean después de guardar los cambios si la precisión es menor que el resultado de la conversión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_real |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena a convertir a número real |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_real('123.45') |
|
</code> |
|
→ |
|
<code> |
|
123.45 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_string"><a href="#conversions-to_string-idx"> |
|
función to_string |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte un número en cadena. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_string |
|
</span> |
|
( |
|
<span class="argument"> |
|
number |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
number |
|
</td> |
|
<td> |
|
Valor entero o real. El número a convertir en cadena. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_string(123) |
|
</code> |
|
→ |
|
<code> |
|
'123' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="conversions-to_time"><a href="#conversions-to_time-idx"> |
|
función to_time |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Converts a string into a time object. An optional format string can be provided to parse the string; see |
|
<a href="https://doc.qt.io/qt-5/qtime.html#fromString-1"> |
|
QTime::fromString |
|
</a> |
|
for additional documentation on the format. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_time |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
[, |
|
<span class="argument"> |
|
format |
|
</span> |
|
][, |
|
<span class="argument"> |
|
language |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena que representa un valor hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
format |
|
</td> |
|
<td> |
|
formato utilizado para convertir la cadena a hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
language |
|
</td> |
|
<td> |
|
idioma (minúsculas, dos- o tres-letras, código de idioma ISO 639) usado para convertir la cadena a hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_time('12:30:01') |
|
</code> |
|
→ |
|
<code> |
|
12:30:01 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_time('12:34','HH:mm') |
|
</code> |
|
→ |
|
<code> |
|
12:34:00 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_time('12:34','HH:mm','fr') |
|
</code> |
|
→ |
|
<code> |
|
12:34:00 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="date-and-time" class="group"><h2><a href="#date-and-time-idx">grupo fecha y hora</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones para manipular datos de fecha y hora.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-age"><a href="#date-and-time-age-idx"> |
|
función age |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la diferencia entre dos fechas o fechas y horas. |
|
<br/> |
|
La diferencia se devuelve como un |
|
<code> |
|
Intervalo |
|
</code> |
|
y es necesario usarla con una de las siguientes funciones para extraer información útil: |
|
<br/> |
|
</p> |
|
<ul> |
|
<li> |
|
<code> |
|
año |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
mes |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
semana |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
día |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hora |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
minuto |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
segundo |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
age |
|
</span> |
|
( |
|
<span class="argument"> |
|
datetime1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
datetime2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
datetime1 |
|
</td> |
|
<td> |
|
una cadena, fecha o fecha y hora que representa la fecha posterior |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
datetime2 |
|
</td> |
|
<td> |
|
una cadena, fecha o fecha y hora que representa la fecha anterior |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
day(age('2012-05-12','2012-05-02')) |
|
</code> |
|
→ |
|
<code> |
|
10 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hour(age('2012-05-12','2012-05-02')) |
|
</code> |
|
→ |
|
<code> |
|
240 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-datetime_from_epoch"><a href="#date-and-time-datetime_from_epoch-idx"> |
|
función datetime_from_epoch |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a datetime whose date and time are the number of milliseconds, msecs, that have passed since 1970-01-01T00:00:00.000, Coordinated Universal Time (Qt.UTC), and converted to Qt.LocalTime. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
datetime_from_epoch |
|
</span> |
|
( |
|
<span class="argument"> |
|
int |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
int |
|
</td> |
|
<td> |
|
number (milliseconds) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
datetime_from_epoch(1483225200000) |
|
</code> |
|
→ |
|
<code> |
|
2017-01-01T00:00:00 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-day"><a href="#date-and-time-day-idx"> |
|
función day |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extracts the day from a date, or the number of days from an interval. |
|
</p> |
|
</div> |
|
<h3 id="date-and-time-day"><a href="#date-and-time-day-idx"> |
|
Variante de fecha |
|
</a></h3> |
|
<div class="description"> |
|
Extracts the day from a date or datetime. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
day |
|
</span> |
|
( |
|
<span class="argument"> |
|
date |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
date |
|
</td> |
|
<td> |
|
una fecha o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
day('2012-05-12') |
|
</code> |
|
→ |
|
<code> |
|
12 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="date-and-time-day"><a href="#date-and-time-day-idx"> |
|
Variante de intervalo |
|
</a></h3> |
|
<div class="description"> |
|
Calculates the length in days of an interval. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
day |
|
</span> |
|
( |
|
<span class="argument"> |
|
interval |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
interval |
|
</td> |
|
<td> |
|
intervalo del que devolver el número de días |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
day(to_interval('3 days')) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
day(to_interval('3 weeks 2 days')) |
|
</code> |
|
→ |
|
<code> |
|
23 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
day(age('2012-01-01','2010-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
730 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-day_of_week"><a href="#date-and-time-day_of_week-idx"> |
|
función day_of_week |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el día de la semana para una fecha o fecha y hora especificadas. El valor devuelto varía entre 0 y 6, donde 0 corresponde a domingo y 6 a sábado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
day_of_week |
|
</span> |
|
( |
|
<span class="argument"> |
|
date |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
date |
|
</td> |
|
<td> |
|
una fecha o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
day_of_week(to_date('2015-09-21')) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-epoch"><a href="#date-and-time-epoch-idx"> |
|
función epoch |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the interval in milliseconds between the unix epoch and a given date value. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
epoch |
|
</span> |
|
( |
|
<span class="argument"> |
|
date |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
date |
|
</td> |
|
<td> |
|
una fecha o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
epoch(to_date('2017-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
1483203600000 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-format_date"><a href="#date-and-time-format_date-idx"> |
|
función format_date |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Formats a date type or string into a custom string format. Uses Qt date/time format strings. See |
|
<a href="https://doc.qt.io/qt-5/qdatetime.html#toString"> |
|
QDateTime::toString |
|
</a> |
|
. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
format_date |
|
</span> |
|
( |
|
<span class="argument"> |
|
datetime |
|
</span> |
|
, |
|
<span class="argument"> |
|
format |
|
</span> |
|
[, |
|
<span class="argument"> |
|
language |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
datetime |
|
</td> |
|
<td> |
|
valor de fecha, hora o fecha y hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
format |
|
</td> |
|
<td> |
|
String template used to format the string. |
|
<table> |
|
<thead> |
|
<tr> |
|
<th> |
|
Expression |
|
</th> |
|
<th> |
|
Output |
|
</th> |
|
</tr> |
|
</thead> |
|
<tr valign="top"> |
|
<td> |
|
d |
|
</td> |
|
<td> |
|
the day as number without a leading zero (1 to 31) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
dd |
|
</td> |
|
<td> |
|
the day as number with a leading zero (01 to 31) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
ddd |
|
</td> |
|
<td> |
|
the abbreviated localized day name (e.g. 'Mon' to 'Sun') |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
dddd |
|
</td> |
|
<td> |
|
the long localized day name (e.g. 'Monday' to 'Sunday') |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
M |
|
</td> |
|
<td> |
|
the month as number without a leading zero (1-12) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
MM |
|
</td> |
|
<td> |
|
the month as number with a leading zero (01-12) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
MMM |
|
</td> |
|
<td> |
|
the abbreviated localized month name (e.g. 'Jan' to 'Dec') |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
MMMM |
|
</td> |
|
<td> |
|
the long localized month name (e.g. 'January' to 'December') |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
yy |
|
</td> |
|
<td> |
|
the year as two digit number (00-99) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
yyyy |
|
</td> |
|
<td> |
|
the year as four digit number |
|
</td> |
|
</tr> |
|
</table> |
|
<p> |
|
These expressions may be used for the time part of the format string: |
|
</p> |
|
<table> |
|
<thead> |
|
<tr> |
|
<th> |
|
Expression |
|
</th> |
|
<th> |
|
Output |
|
</th> |
|
</tr> |
|
</thead> |
|
<tr valign="top"> |
|
<td> |
|
h |
|
</td> |
|
<td> |
|
the hour without a leading zero (0 to 23 or 1 to 12 if AM/PM display) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
hh |
|
</td> |
|
<td> |
|
the hour with a leading zero (00 to 23 or 01 to 12 if AM/PM display) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
H |
|
</td> |
|
<td> |
|
the hour without a leading zero (0 to 23, even with AM/PM display) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
HH |
|
</td> |
|
<td> |
|
the hour with a leading zero (00 to 23, even with AM/PM display) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
m |
|
</td> |
|
<td> |
|
the minute without a leading zero (0 to 59) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
mm |
|
</td> |
|
<td> |
|
the minute with a leading zero (00 to 59) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
s |
|
</td> |
|
<td> |
|
the second without a leading zero (0 to 59) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
ss |
|
</td> |
|
<td> |
|
the second with a leading zero (00 to 59) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
z |
|
</td> |
|
<td> |
|
the milliseconds without trailing zeroes (0 to 999) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
zzz |
|
</td> |
|
<td> |
|
the milliseconds with trailing zeroes (000 to 999) |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
AP or A |
|
</td> |
|
<td> |
|
interpret as an AM/PM time. |
|
<i> |
|
AP |
|
</i> |
|
must be either "AM" or "PM". |
|
</td> |
|
</tr> |
|
<tr valign="top"> |
|
<td> |
|
ap or a |
|
</td> |
|
<td> |
|
Interpret as an AM/PM time. |
|
<i> |
|
ap |
|
</i> |
|
must be either "am" or "pm". |
|
</td> |
|
</tr> |
|
</table> |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
language |
|
</td> |
|
<td> |
|
language (lowercase, two- or three-letter, ISO 639 language code) used to format the date into a custom string |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
format_date('2012-05-15','dd.MM.yyyy') |
|
</code> |
|
→ |
|
<code> |
|
'15.05.2012' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
format_date('2012-05-15','d MMMM yyyy','fr') |
|
</code> |
|
→ |
|
<code> |
|
'15 juin 2012' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-hour"><a href="#date-and-time-hour-idx"> |
|
función hour |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extracts the hour part from a datetime or time, or the number of hours from an interval. |
|
</p> |
|
</div> |
|
<h3 id="date-and-time-hour"><a href="#date-and-time-hour-idx"> |
|
Variante de hora |
|
</a></h3> |
|
<div class="description"> |
|
Extracts the hour part from a time or datetime. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
hour |
|
</span> |
|
( |
|
<span class="argument"> |
|
datetime |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
datetime |
|
</td> |
|
<td> |
|
un valor de hora o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
hour('2012-07-22T13:24:57') |
|
</code> |
|
→ |
|
<code> |
|
13 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="date-and-time-hour"><a href="#date-and-time-hour-idx"> |
|
Variante de intervalo |
|
</a></h3> |
|
<div class="description"> |
|
Calculates the length in hours of an interval. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
hour |
|
</span> |
|
( |
|
<span class="argument"> |
|
interval |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
interval |
|
</td> |
|
<td> |
|
intervalo del que devolver el número de horas |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
hour(tointerval('3 horas')) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hour(age('2012-07-22T13:00:00','2012-07-22T10:00:00')) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hour(age('2012-01-01','2010-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
17520 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-make_date"><a href="#date-and-time-make_date-idx"> |
|
función make_date |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a date value from year, month and day numbers. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_date |
|
</span> |
|
( |
|
<span class="argument"> |
|
year |
|
</span> |
|
, |
|
<span class="argument"> |
|
month |
|
</span> |
|
, |
|
<span class="argument"> |
|
day |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
year |
|
</td> |
|
<td> |
|
Year number. Years 1 to 99 are interpreted as is. Year 0 is invalid. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
month |
|
</td> |
|
<td> |
|
Month number, where 1=January |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
day |
|
</td> |
|
<td> |
|
Day number, beginning with 1 for the first day in the month |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
make_date(2020,5,4) |
|
</code> |
|
→ |
|
<code> |
|
date value 2020-05-04 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-make_datetime"><a href="#date-and-time-make_datetime-idx"> |
|
función make_datetime |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a datetime value from year, month, day, hour, minute and second numbers. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_datetime |
|
</span> |
|
( |
|
<span class="argument"> |
|
year |
|
</span> |
|
, |
|
<span class="argument"> |
|
month |
|
</span> |
|
, |
|
<span class="argument"> |
|
day |
|
</span> |
|
, |
|
<span class="argument"> |
|
hour |
|
</span> |
|
, |
|
<span class="argument"> |
|
minute |
|
</span> |
|
, |
|
<span class="argument"> |
|
second |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
year |
|
</td> |
|
<td> |
|
Year number. Years 1 to 99 are interpreted as is. Year 0 is invalid. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
month |
|
</td> |
|
<td> |
|
Month number, where 1=January |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
day |
|
</td> |
|
<td> |
|
Day number, beginning with 1 for the first day in the month |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
hour |
|
</td> |
|
<td> |
|
Hour number |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
minute |
|
</td> |
|
<td> |
|
Minutes |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
second |
|
</td> |
|
<td> |
|
Seconds (fractional values include milliseconds) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
make_datetime(2020,5,4,13,45,30.5) |
|
</code> |
|
→ |
|
<code> |
|
datetime value 2020-05-04 13:45:30.500 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-make_interval"><a href="#date-and-time-make_interval-idx"> |
|
función make_interval |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates an interval value from year, month, weeks, days, hours, minute and seconds values. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_interval |
|
</span> |
|
([ |
|
<span class="argument"> |
|
years=0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
months=0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
weeks=0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
days=0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
hours=0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
minutes=0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
seconds=0 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
years |
|
</td> |
|
<td> |
|
Number of years (assumes a 365.25 day year length). |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
months |
|
</td> |
|
<td> |
|
Number of months (assumes a 30 day month length) |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
weeks |
|
</td> |
|
<td> |
|
Number of weeks |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
days |
|
</td> |
|
<td> |
|
Number of days |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
hours |
|
</td> |
|
<td> |
|
Number of hours |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
minutes |
|
</td> |
|
<td> |
|
Number of minutes |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
seconds |
|
</td> |
|
<td> |
|
Number of seconds |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
make_interval(hours:=3) |
|
</code> |
|
→ |
|
<code> |
|
3 hour interval |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
make_interval(days:=2, hours:=3) |
|
</code> |
|
→ |
|
<code> |
|
2 day, 3 hour interval |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-make_time"><a href="#date-and-time-make_time-idx"> |
|
función make_time |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a time value from hour, minute and second numbers. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_time |
|
</span> |
|
( |
|
<span class="argument"> |
|
hour |
|
</span> |
|
, |
|
<span class="argument"> |
|
minute |
|
</span> |
|
, |
|
<span class="argument"> |
|
second |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
hour |
|
</td> |
|
<td> |
|
Hour number |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
minute |
|
</td> |
|
<td> |
|
Minutes |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
second |
|
</td> |
|
<td> |
|
Seconds (fractional values include milliseconds) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
make_time(13,45,30.5) |
|
</code> |
|
→ |
|
<code> |
|
time value 13:45:30.500 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-minute"><a href="#date-and-time-minute-idx"> |
|
función minute |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extracts the minutes part from a datetime or time, or the number of minutes from an interval. |
|
</p> |
|
</div> |
|
<h3 id="date-and-time-minute"><a href="#date-and-time-minute-idx"> |
|
Variante de hora |
|
</a></h3> |
|
<div class="description"> |
|
Extracts the minutes part from a time or datetime. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
minute |
|
</span> |
|
( |
|
<span class="argument"> |
|
datetime |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
datetime |
|
</td> |
|
<td> |
|
un valor de hora o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
minute('2012-07-22T13:24:57') |
|
</code> |
|
→ |
|
<code> |
|
24 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="date-and-time-minute"><a href="#date-and-time-minute-idx"> |
|
Variante de intervalo |
|
</a></h3> |
|
<div class="description"> |
|
Calculates the length in minutes of an interval. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
minute |
|
</span> |
|
( |
|
<span class="argument"> |
|
interval |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
interval |
|
</td> |
|
<td> |
|
intervalo del que devolver el número de minutos |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
minute(tointerval('3 minutos')) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
minute(age('2012-07-22T00:20:00','2012-07-22T00:00:00')) |
|
</code> |
|
→ |
|
<code> |
|
20 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
minute(age('2012-01-01','2010-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
1051200 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-month"><a href="#date-and-time-month-idx"> |
|
función month |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extracts the month part from a date, or the number of months from an interval. |
|
</p> |
|
</div> |
|
<h3 id="date-and-time-month"><a href="#date-and-time-month-idx"> |
|
Variante de fecha |
|
</a></h3> |
|
<div class="description"> |
|
Extracts the month part from a date or datetime. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
month |
|
</span> |
|
( |
|
<span class="argument"> |
|
date |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
date |
|
</td> |
|
<td> |
|
una fecha o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
month('2012-05-12') |
|
</code> |
|
→ |
|
<code> |
|
05 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="date-and-time-month"><a href="#date-and-time-month-idx"> |
|
Variante de intervalo |
|
</a></h3> |
|
<div class="description"> |
|
Calculates the length in months of an interval. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
month |
|
</span> |
|
( |
|
<span class="argument"> |
|
interval |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
interval |
|
</td> |
|
<td> |
|
intervalo del que devolver el número de meses |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
month(to_interval('3 meses')) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
month(age('2012-01-01','2010-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
4.03333 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-now"><a href="#date-and-time-now-idx"> |
|
función now |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the current date and time. The function is static and will return consistent results while evaluating. The time returned is the time when the expression is prepared. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
now |
|
</span> |
|
() |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
now() |
|
</code> |
|
→ |
|
<code> |
|
2012-07-22T13:24:57 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-second"><a href="#date-and-time-second-idx"> |
|
función second |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extracts the seconds part from a datetime or time, or the number of seconds from an interval. |
|
</p> |
|
</div> |
|
<h3 id="date-and-time-second"><a href="#date-and-time-second-idx"> |
|
Variante de hora |
|
</a></h3> |
|
<div class="description"> |
|
Extracts the seconds part from a time or datetime. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
second |
|
</span> |
|
( |
|
<span class="argument"> |
|
datetime |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
datetime |
|
</td> |
|
<td> |
|
un valor de hora o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
second('2012-07-22T13:24:57') |
|
</code> |
|
→ |
|
<code> |
|
57 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="date-and-time-second"><a href="#date-and-time-second-idx"> |
|
Variante de intervalo |
|
</a></h3> |
|
<div class="description"> |
|
Calculates the length in seconds of an interval. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
second |
|
</span> |
|
( |
|
<span class="argument"> |
|
interval |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
interval |
|
</td> |
|
<td> |
|
intervalo del que devolver el número de segundos |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
second(age('2012-07-22T00:20:00','2012-07-22T00:00:00')) |
|
</code> |
|
→ |
|
<code> |
|
1200 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
second(age('2012-01-01','2010-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
63072000 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-to_date"><a href="#date-and-time-to_date-idx"> |
|
función to_date |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte una cadena de caracteres en un objeto fecha. Una cadena opcional de formato puede proporcionarse para formatear la cadena; ver |
|
<a href="https://doc.qt.io/qt-5/qdate.html#fromString-1"> |
|
QDate::fromString |
|
</a> |
|
para documentación adicional sobre el formato. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_date |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
[, |
|
<span class="argument"> |
|
format |
|
</span> |
|
][, |
|
<span class="argument"> |
|
language |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena que representa un valor de fecha |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
format |
|
</td> |
|
<td> |
|
format used to convert the string into a date |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
language |
|
</td> |
|
<td> |
|
idioma (minúsculas, dos- o tres-letras, código de idioma ISO 639) usado para convertir la cadena a fecha |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_date('2012-05-04') |
|
</code> |
|
→ |
|
<code> |
|
2012-05-04 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_date('June 29, 2019','MMMM d, yyyy') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_date('29 juin, 2019','d MMMM, yyyy','fr') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-to_datetime"><a href="#date-and-time-to_datetime-idx"> |
|
función to_datetime |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte una cadena de caracteres en un objeto fecha-hora. Una cadena opcional de formato puede proporcionarse para formatear la cadena; ver |
|
<a href="https://doc.qt.io/qt-5/qdatetime.html#fromString-1"> |
|
QDate::fromString |
|
</a> |
|
para documentación adicional sobre el formato. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_datetime |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
[, |
|
<span class="argument"> |
|
format |
|
</span> |
|
][, |
|
<span class="argument"> |
|
language |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena que representa un valor de fecha y hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
format |
|
</td> |
|
<td> |
|
formato usado para convertir la cadena a fecha-hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
language |
|
</td> |
|
<td> |
|
idioma (minúsculas, dos- o tres-letras, código de idioma ISO 639) usado para convertir la cadena a fecha-hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_datetime('2012-05-04 12:50:00') |
|
</code> |
|
→ |
|
<code> |
|
2012-05-04T12:50:00 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_datetime('June 29, 2019 @ 12:34','MMMM d, yyyy @ HH:mm') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29T12:34 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_datetime('29 juin, 2019 @ 12:34','d MMMM, yyyy @ HH:mm','fr') |
|
</code> |
|
→ |
|
<code> |
|
2019-06-29T12:34 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-to_interval"><a href="#date-and-time-to_interval-idx"> |
|
función to_interval |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Converts a string to a interval type. Can be used to take days, hours, month, etc of a date. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_interval |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
una cadena que representa un intervalo. Los formatos permitidos incluyen {n} días {n} horas {n} meses. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_datetime('2012-05-05 12:00:00') - to_interval('1 día 2 horas') |
|
</code> |
|
→ |
|
<code> |
|
2012-05-04T10:00:00 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-to_time"><a href="#date-and-time-to_time-idx"> |
|
función to_time |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Converts a string into a time object. An optional format string can be provided to parse the string; see |
|
<a href="https://doc.qt.io/qt-5/qtime.html#fromString-1"> |
|
QTime::fromString |
|
</a> |
|
for additional documentation on the format. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_time |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
[, |
|
<span class="argument"> |
|
format |
|
</span> |
|
][, |
|
<span class="argument"> |
|
language |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena que representa un valor hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
format |
|
</td> |
|
<td> |
|
formato utilizado para convertir la cadena a hora |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
language |
|
</td> |
|
<td> |
|
idioma (minúsculas, dos- o tres-letras, código de idioma ISO 639) usado para convertir la cadena a hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_time('12:30:01') |
|
</code> |
|
→ |
|
<code> |
|
12:30:01 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_time('12:34','HH:mm') |
|
</code> |
|
→ |
|
<code> |
|
12:34:00 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_time('12:34','HH:mm','fr') |
|
</code> |
|
→ |
|
<code> |
|
12:34:00 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-week"><a href="#date-and-time-week-idx"> |
|
función week |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extracts the week number from a date, or the number of weeks from an interval. |
|
</p> |
|
</div> |
|
<h3 id="date-and-time-week"><a href="#date-and-time-week-idx"> |
|
Variante de fecha |
|
</a></h3> |
|
<div class="description"> |
|
Extracts the week number from a date or datetime. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
week |
|
</span> |
|
( |
|
<span class="argument"> |
|
date |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
date |
|
</td> |
|
<td> |
|
una fecha o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
week('2012-05-12') |
|
</code> |
|
→ |
|
<code> |
|
19 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="date-and-time-week"><a href="#date-and-time-week-idx"> |
|
Variante de intervalo |
|
</a></h3> |
|
<div class="description"> |
|
Calculates the length in weeks of an interval. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
week |
|
</span> |
|
( |
|
<span class="argument"> |
|
interval |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
interval |
|
</td> |
|
<td> |
|
intervalo del que devolver el número de meses |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
week(to_interval('3 weeks')) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
week(age('2012-01-01','2010-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
104.285 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="date-and-time-year"><a href="#date-and-time-year-idx"> |
|
función year |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extracts the year part from a date, or the number of years from an interval. |
|
</p> |
|
</div> |
|
<h3 id="date-and-time-year"><a href="#date-and-time-year-idx"> |
|
Variante de fecha |
|
</a></h3> |
|
<div class="description"> |
|
Extracts the year part from a date or datetime. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
year |
|
</span> |
|
( |
|
<span class="argument"> |
|
date |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
date |
|
</td> |
|
<td> |
|
una fecha o fecha y hora |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
year('2012-05-12') |
|
</code> |
|
→ |
|
<code> |
|
2012 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="date-and-time-year"><a href="#date-and-time-year-idx"> |
|
Variante de intervalo |
|
</a></h3> |
|
<div class="description"> |
|
Calculates the length in years of an interval. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
year |
|
</span> |
|
( |
|
<span class="argument"> |
|
interval |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
interval |
|
</td> |
|
<td> |
|
intervalo del que devolver el número de años |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
year(to_interval('3 años')) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
year(age('2012-01-01','2010-01-01')) |
|
</code> |
|
→ |
|
<code> |
|
1.9986 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="files-and-paths" class="group"><h2><a href="#files-and-paths-idx">grupo files and paths</a></h2> |
|
<div class="description"><p>Contains functions which manipulate file and path names.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-base_file_name"><a href="#files-and-paths-base_file_name-idx"> |
|
función base_file_name |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the base name of the file without the directory or file suffix. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
base_file_name |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
base_file_name('/home/qgis/data/country_boundaries.shp') |
|
</code> |
|
→ |
|
<code> |
|
'country_boundaries' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-file_exists"><a href="#files-and-paths-file_exists-idx"> |
|
función file_exists |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if a file path exists. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
file_exists |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
file_exists('/home/qgis/data/country_boundaries.shp') |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-file_name"><a href="#files-and-paths-file_name-idx"> |
|
función file_name |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the name of a file (including the file extension), excluding the directory. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
file_name |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
file_name('/home/qgis/data/country_boundaries.shp') |
|
</code> |
|
→ |
|
<code> |
|
'country_boundaries.shp' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-file_path"><a href="#files-and-paths-file_path-idx"> |
|
función file_path |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the directory component of a file path. This does not include the file name. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
file_path |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
file_path('/home/qgis/data/country_boundaries.shp') |
|
</code> |
|
→ |
|
<code> |
|
'/home/qgis/data' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-file_size"><a href="#files-and-paths-file_size-idx"> |
|
función file_size |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the size (in bytes) of a file. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
file_size |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
file_size('/home/qgis/data/country_boundaries.geojson') |
|
</code> |
|
→ |
|
<code> |
|
5674 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-file_suffix"><a href="#files-and-paths-file_suffix-idx"> |
|
función file_suffix |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the file suffix (extension) from a file path. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
file_suffix |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
file_suffix('/home/qgis/data/country_boundaries.shp') |
|
</code> |
|
→ |
|
<code> |
|
'shp' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-is_directory"><a href="#files-and-paths-is_directory-idx"> |
|
función is_directory |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if a path corresponds to a directory. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_directory |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_directory('/home/qgis/data/country_boundaries.shp') |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_directory('/home/qgis/data/') |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="files-and-paths-is_file"><a href="#files-and-paths-is_file-idx"> |
|
función is_file |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if a path corresponds to a file. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_file |
|
</span> |
|
( |
|
<span class="argument"> |
|
path |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
path |
|
</td> |
|
<td> |
|
a file path |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_file('/home/qgis/data/country_boundaries.shp') |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_file('/home/qgis/data/') |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="form" class="group">falta la ayuda de la función para Form</div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="form-current_parent_value"><a href="#form-current_parent_value-idx"> |
|
función current_parent_value |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Only usable in an embedded form context, this function returns the current, unsaved value of a field in the parent form currently being edited. This will differ from the parent feature's actual attribute values for features which are currently being edited or have not yet been added to a parent layer. When used in a value-relation widget filter expression, this function should be wrapped into a 'coalesce()' that can retrieve the actual parent feature from the layer when the form is not used in an embedded context. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
current_parent_value |
|
</span> |
|
( |
|
<span class="argument"> |
|
field_name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
field_name |
|
</td> |
|
<td> |
|
a field name in the current parent form |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
current_parent_value( 'FIELD_NAME' ) |
|
</code> |
|
→ |
|
<code> |
|
The current value of a field 'FIELD_NAME' in the parent form. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="form-current_value"><a href="#form-current_value-idx"> |
|
función current_value |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the current, unsaved value of a field in the form or table row currently being edited. This will differ from the feature's actual attribute values for features which are currently being edited or have not yet been added to a layer. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
current_value |
|
</span> |
|
( |
|
<span class="argument"> |
|
field_name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
field_name |
|
</td> |
|
<td> |
|
a field name in the current form or table row |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
current_value( 'FIELD_NAME' ) |
|
</code> |
|
→ |
|
<code> |
|
The current value of field 'FIELD_NAME'. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="fuzzy-matching" class="group"><h2><a href="#fuzzy-matching-idx">grupo concordancia aproximada</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones para comparaciones simples entre valores.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="fuzzy-matching-hamming_distance"><a href="#fuzzy-matching-hamming_distance-idx"> |
|
función hamming_distance |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la distancia de Hamming entre dos cadenas. Esto es igual al número de caracteres en las posiciones correspondientes dentro de las cadenas de entrada donde los caracteres son diferentes. Las cadenas de entrada deben tener la misma longitud y la comparación es sensible a mayúsculas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
hamming_distance |
|
</span> |
|
( |
|
<span class="argument"> |
|
string1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
string2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string1 |
|
</td> |
|
<td> |
|
una cadena |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
string2 |
|
</td> |
|
<td> |
|
una cadena |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
hamming_distance('abc','xec') |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hamming_distance('abc','ABc') |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hamming_distance(upper('abc'),upper('ABC')) |
|
</code> |
|
→ |
|
<code> |
|
0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="fuzzy-matching-levenshtein"><a href="#fuzzy-matching-levenshtein-idx"> |
|
función levenshtein |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la distancia de edición de Levenshtein entre dos cadenas. Esto es el número mínimo de ediciones de caracteres (inserciones, borrados o sustituciones) necesario para convertir una cadena en otra. |
|
<br/> |
|
La distancia de Levenshtein es una medida de la similitud entre dos cadenas. Distancias menores significan que las cadenas son más parecidas y distancias mayores indican más diferencia entre las cadenas. La distancia distingue entre mayúsculas y minúsculas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
levenshtein |
|
</span> |
|
( |
|
<span class="argument"> |
|
string1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
string2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string1 |
|
</td> |
|
<td> |
|
una cadena |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
string2 |
|
</td> |
|
<td> |
|
una cadena |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
levenshtein('mínimo','máximo') |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
levenshtein('Mínimo','mínimo') |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
levenshtein(upper('Mínimo'),upper('mínimo')) |
|
</code> |
|
→ |
|
<code> |
|
0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="fuzzy-matching-longest_common_substring"><a href="#fuzzy-matching-longest_common_substring-idx"> |
|
función longest_common_substring |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la subcadena común más larga entre dos cadenas. Esta subcadena es la más larga que es una subcadena de las dos cadenas de entrada. Por ejemplo, la subcadena más larga común de "ABABC" y "BABCA" es "ABC". La subcadena distingue mayúsculas/minúsculas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
longest_common_substring |
|
</span> |
|
( |
|
<span class="argument"> |
|
string1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
string2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string1 |
|
</td> |
|
<td> |
|
una cadena |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
string2 |
|
</td> |
|
<td> |
|
una cadena |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
longest_common_substring('ABABC','BABCA') |
|
</code> |
|
→ |
|
<code> |
|
'ABC' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
longest_common_substring('abcDeF','abcdef') |
|
</code> |
|
→ |
|
<code> |
|
'abc' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
longest_common_substring(upper('abcDeF'),upper('abcdex')) |
|
</code> |
|
→ |
|
<code> |
|
'ABCDE' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="fuzzy-matching-soundex"><a href="#fuzzy-matching-soundex-idx"> |
|
función soundex |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la representación Soundex de una cadena. Soundex es un algoritmo de coincidencia fonética, de forma que cadenas con sonidos similares deben representarse por el mismo código Soundex. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
soundex |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
una cadena |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
soundex('robert') |
|
</code> |
|
→ |
|
<code> |
|
'R163' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
soundex('rupert') |
|
</code> |
|
→ |
|
<code> |
|
'R163' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
soundex('rubin') |
|
</code> |
|
→ |
|
<code> |
|
'R150' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="general" class="group"><h2><a href="#general-idx">grupo general</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones generales variadas.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="general-env"><a href="#general-env-idx"> |
|
función env |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Obtiene una variable de entorno y devuelve su contenido como cadena. Si la variable no se encuentra devuelve "NULO". Esto es útil para introducir configuraciones específicas del sistema, como la letra de unidad o prefijos de rutas. La definición de variables de entorno depende del sistema operativo, por favor consulte cómo se puede establecer con el administrador de su equipo o en la documentación del sistema operativo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
env |
|
</span> |
|
( |
|
<span class="argument"> |
|
name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
name |
|
</td> |
|
<td> |
|
El nombre de la variable de entorno que de debe recuperar. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
env( 'LANG' ) |
|
</code> |
|
→ |
|
<code> |
|
'en_US.UTF-8' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
env( 'MY_OWN_PREFIX_VAR' ) |
|
</code> |
|
→ |
|
<code> |
|
'Z:' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
env( 'I_DO_NOT_EXIST' ) |
|
</code> |
|
→ |
|
<code> |
|
NULO |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="general-eval"><a href="#general-eval-idx"> |
|
función eval |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Evalúa una expresión que es pasada en una cadena. Útil para expandir parámetros dinámicos pasados como variables de contexto o campos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
eval |
|
</span> |
|
( |
|
<span class="argument"> |
|
expression |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
una cadena de expresión |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
eval(''nice'') |
|
</code> |
|
→ |
|
<code> |
|
'nice' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
eval(@expression_var) |
|
</code> |
|
→ |
|
<code> |
|
[whatever the result of evaluating @expression_var might be…] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="general-eval_template"><a href="#general-eval_template-idx"> |
|
función eval_template |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Evaluates a template which is passed in a string. Useful to expand dynamic parameters passed as context variables or fields. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
eval_template |
|
</span> |
|
( |
|
<span class="argument"> |
|
template |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
template |
|
</td> |
|
<td> |
|
a template string |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
eval_template('QGIS [% upper(\'rocks\') %]') |
|
</code> |
|
→ |
|
<code> |
|
QGIS ROCKS |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="general-is_layer_visible"><a href="#general-is_layer_visible-idx"> |
|
función is_layer_visible |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve verdadero si la capa especificada es visible. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_layer_visible |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
Una cadena que represente el nombre o la ID de una capa |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_layer_visible('baseraster') |
|
</code> |
|
→ |
|
<code> |
|
Verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="general-layer_property"><a href="#general-layer_property-idx"> |
|
función layer_property |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor de una propiedad o metadato de una capa. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
layer_property |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
, |
|
<span class="argument"> |
|
property |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
Una cadena que represente el nombre o la ID de una capa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
property |
|
</td> |
|
<td> |
|
a string corresponding to the property to return. Valid options are: |
|
<br/> |
|
<ul> |
|
<li> |
|
name: layer name |
|
</li> |
|
<li> |
|
id: layer ID |
|
</li> |
|
<li> |
|
title: metadata title string |
|
</li> |
|
<li> |
|
abstract: metadata abstract string |
|
</li> |
|
<li> |
|
keywords: metadata keywords |
|
</li> |
|
<li> |
|
data_url: metadata URL |
|
</li> |
|
<li> |
|
attribution: metadata attribution string |
|
</li> |
|
<li> |
|
attribution_url: metadata attribution URL |
|
</li> |
|
<li> |
|
source: layer source |
|
</li> |
|
<li> |
|
min_scale: minimum display scale for layer |
|
</li> |
|
<li> |
|
max_scale: maximum display scale for layer |
|
</li> |
|
<li> |
|
is_editable: if layer is in edit mode |
|
</li> |
|
<li> |
|
crs: layer CRS |
|
</li> |
|
<li> |
|
crs_definition: layer CRS full definition |
|
</li> |
|
<li> |
|
crs_description: layer CRS description |
|
</li> |
|
<li> |
|
extent: layer extent (as a geometry object) |
|
</li> |
|
<li> |
|
distance_units: layer distance units |
|
</li> |
|
<li> |
|
type: layer type, e.g., Vector or Raster |
|
</li> |
|
<li> |
|
storage_type: storage format (vector layers only) |
|
</li> |
|
<li> |
|
geometry_type: geometry type, e.g., Point (vector layers only) |
|
</li> |
|
<li> |
|
feature_count: approximate feature count for layer (vector layers only) |
|
</li> |
|
<li> |
|
path: File path to the layer data source. Only available for file based layers. |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
layer_property('calles','title') |
|
</code> |
|
→ |
|
<code> |
|
'Mapa base de calles' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
layer_property('aeropuertos','feature_count') |
|
</code> |
|
→ |
|
<code> |
|
120 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
layer_property('landsat','crs') |
|
</code> |
|
→ |
|
<code> |
|
'EPSG:4326' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="general-var"><a href="#general-var-idx"> |
|
función var |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor guardado dentro de una variable especificada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
var |
|
</span> |
|
( |
|
<span class="argument"> |
|
name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
name |
|
</td> |
|
<td> |
|
un nombre de variable |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
var('qgis_version') |
|
</code> |
|
→ |
|
<code> |
|
'2.12' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="general-with_variable"><a href="#general-with_variable-idx"> |
|
función with_variable |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Esta función establece una variable para el código de cualquier expresión que se proporcionará como tercer argumento. Esto solo es útil para expresiones complejas, en las que se necesita usar el mismo valor calculado en diferentes sitios. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
with_variable |
|
</span> |
|
( |
|
<span class="argument"> |
|
name |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
, |
|
<span class="argument"> |
|
expression |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
name |
|
</td> |
|
<td> |
|
el nombre de la variable a establecer |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
el valor a establecer |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
expression |
|
</td> |
|
<td> |
|
la expresión para la que estará disponible la variable |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
with_variable('my_sum', 1 + 2 + 3, @my_sum * 2 + @my_sum * 5) |
|
</code> |
|
→ |
|
<code> |
|
42 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="geometrygroup" class="group"><h2><a href="#geometrygroup-idx">grupo geometría</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones que operan sobre elementos de geometría, como longitud o área.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-area"><a href="#geometrygroup-dollar-area-idx"> |
|
función $area |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el área del objeto actual. El área calculada por esta función respeta tanto la configuración del elipsoide del proyecto actual como la de las unidades de área. Por ejemplo, si se ha establecido un elipsoide para el proyecto, entonces el área calculada será elipsoidal y si no se ha establecido ningún elipsoide, entonces el área calculada será planimétrica. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$area |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$area |
|
</code> |
|
→ |
|
<code> |
|
42 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-geometry"><a href="#geometrygroup-dollar-geometry-idx"> |
|
función $geometry |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la geometría del objeto actual. Se puede usar para procesos con otras funciones. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$geometry |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geomToWKT( $geometry ) |
|
</code> |
|
→ |
|
<code> |
|
PUNTO(6 50) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-length"><a href="#geometrygroup-dollar-length-idx"> |
|
función $length |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la longitud de una cadena de líneas. Si necesita la longitud del contorno de un polígono, utilice mejor $perimeter. La longitud calculada por esta función respeta tanto la configuración del elipsoide del proyecto actual como la de las unidades de longitud. Por ejemplo, si se ha establecido un elipsoide para el proyecto, entonces la longitud calculada será elipsoidal y si no se ha establecido ningún elipsoide, entonces la longitud calculada será planimétrica. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$length |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$length |
|
</code> |
|
→ |
|
<code> |
|
42.4711 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-perimeter"><a href="#geometrygroup-dollar-perimeter-idx"> |
|
función $perimeter |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la longitud del perímetro del objeto actual. El perímetro calculado por esta función respeta tanto la configuración del elipsoide del proyecto actual como la de las unidades de distancia. Por ejemplo, si se ha establecido un elipsoide para el proyecto, entonces el perímetro calculado será elipsoidal y si no se ha establecido ningún elipsoide, entonces el perímetro calculado será planimétrico. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$perimeter |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$perimeter |
|
</code> |
|
→ |
|
<code> |
|
42 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-x"><a href="#geometrygroup-dollar-x-idx"> |
|
función $x |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada X del objeto actual. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$x |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$x |
|
</code> |
|
→ |
|
<code> |
|
42 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-x_at"><a href="#geometrygroup-dollar-x_at-idx"> |
|
función $x_at |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Obtiene una coordenada X de la geometría del objeto actual. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$x_at |
|
</span> |
|
( |
|
<span class="argument"> |
|
i |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
i |
|
</td> |
|
<td> |
|
index of point of a line (indices start at 0; negative values apply from the last index, starting at -1) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$x_at(1) |
|
</code> |
|
→ |
|
<code> |
|
5 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-y"><a href="#geometrygroup-dollar-y-idx"> |
|
función $y |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada Y del objeto actual. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$y |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$y |
|
</code> |
|
→ |
|
<code> |
|
42 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-dollar-y_at"><a href="#geometrygroup-dollar-y_at-idx"> |
|
función $y_at |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Obtiene una coordenada Y de la geometría del objeto actual. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$y_at |
|
</span> |
|
( |
|
<span class="argument"> |
|
i |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
i |
|
</td> |
|
<td> |
|
index of point of a line (indices start at 0; negative values apply from the last index, starting at -1) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$y_at(1) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-angle_at_vertex"><a href="#geometrygroup-angle_at_vertex-idx"> |
|
función angle_at_vertex |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un ángulo bisectriz (ángulo medio) a la geometría para un vértice especificado en una geometría de cadena de línea. Los ángulos están en grados en sentido horario a partir del norte. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
angle_at_vertex |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
vertex |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de cadena de línea |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
vertex |
|
</td> |
|
<td> |
|
vertex index, starting from 0; if the value is negative, the selected vertex index will be its total count minus the absolute value |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
angle_at_vertex(geometry:=geom_from_wkt('LineString(0 0, 10 0, 10 10)'),vertex:=1) |
|
</code> |
|
→ |
|
<code> |
|
45.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-area"><a href="#geometrygroup-area-idx"> |
|
función area |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el área de un objeto de geometría de tipo polígono. Los cálculos siempre son planimétricos en el Sistema de Rerefencia Espacial (SRE) de esta geometría y las unidades del área devuelta coincidirán con las unidades del SRE. Esto difiere de los cálculos hechos por la función $area, que hará cálculos elipsoidales basados en el elipsoide del proyecto y la configuración de las unidades de superficie. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
area |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría poligonal |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
area(geom_from_wkt('POLYGON((0 0, 4 0, 4 2, 0 2, 0 0))')) |
|
</code> |
|
→ |
|
<code> |
|
8.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-azimuth"><a href="#geometrygroup-azimuth-idx"> |
|
función azimuth |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el azimut basado en el Norte como el ángulo en radianes medido en sentido horario desde la vertical en el punto_A al Punto_b. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
azimuth |
|
</span> |
|
( |
|
<span class="argument"> |
|
point_a |
|
</span> |
|
, |
|
<span class="argument"> |
|
point_b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point_a |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point_b |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
degrees( azimuth( make_point(25, 45), make_point(75, 100) ) ) |
|
</code> |
|
→ |
|
<code> |
|
42.273689 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
degrees( azimuth( make_point(75, 100), make_point(25,45) ) ) |
|
</code> |
|
→ |
|
<code> |
|
222.273689 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-boundary"><a href="#geometrygroup-boundary-idx"> |
|
función boundary |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el cierre del límite combinatorio de la geometría (es decir, el límite topológico de la geometría). Por ejemplo, una geometría de polígono tendrá un límite que consta de líneas para cada anillo en el polígono. Algunos tipos de geometría no tienen un límite definido, por ejemplo, puntos o colecciones de geometrías, y se devolverán nulos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
boundary |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(boundary(geom_from_wkt('Polygon((1 1, 0 0, -1 1, 1 1))'))) |
|
</code> |
|
→ |
|
<code> |
|
'LineString(1 1,0 0,-1 1,1 1)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-bounds"><a href="#geometrygroup-bounds-idx"> |
|
función bounds |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría que representa el recuadro delimitador de una geometría de entrada. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
bounds |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
bounds($geometry) |
|
</code> |
|
→ |
|
<code> |
|
recuadro delimitador de $geometry |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-bounds_height"><a href="#geometrygroup-bounds_height-idx"> |
|
función bounds_height |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la altura del recuadro delimitador de una geometría. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
bounds_height |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
bounds_height($geometry) |
|
</code> |
|
→ |
|
<code> |
|
altura del recuadro delimitador de $geometry |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-bounds_width"><a href="#geometrygroup-bounds_width-idx"> |
|
función bounds_width |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la anchura del recuadro delimitador de una geometría. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
bounds_width |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
bounds_width($geometry) |
|
</code> |
|
→ |
|
<code> |
|
anchura del recuadro delimitador de $geometry |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-buffer"><a href="#geometrygroup-buffer-idx"> |
|
función buffer |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría que representa todos los puntos cuya distancia desde esta geometría es menor o igual que distancia. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
buffer |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
, |
|
<span class="argument"> |
|
distance |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segments=8 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
distance |
|
</td> |
|
<td> |
|
distancia de buffer en unidades de la capa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segments |
|
</td> |
|
<td> |
|
número de segmentos a usar para representar un cuarto de círculo cuando se utilice un estilo de unión redondo. Un número mayor da como resultado un buffer más suave con más nodos. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
buffer($geometry, 10.5) |
|
</code> |
|
→ |
|
<code> |
|
polígono de $geometry con un buffer de 10.5 unidades |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-buffer_by_m"><a href="#geometrygroup-buffer_by_m-idx"> |
|
función buffer_by_m |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a buffer along a line geometry where the buffer diameter varies according to the m-values at the line vertices. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
buffer_by_m |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segments=8 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
geometría de entrada. Debe ser una geometría (de varias líneas) con valores m. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segments |
|
</td> |
|
<td> |
|
número de segmentos para aproximar las curvas del un cuarto de círculo en el buffer. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
buffer_by_m(geometry:=geom_from_wkt('LINESTRINGM(1 2 0.5, 4 2 0.2)'),segments:=8) |
|
</code> |
|
→ |
|
<code> |
|
Un búfer de ancho variable que comienza con un diámetro de 0.5 y termina con un diámetro de 0.2 a lo largo de la geometría lineal. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-centroid"><a href="#geometrygroup-centroid-idx"> |
|
función centroid |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el centro geométrico de una geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
centroid |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
centroid($geometry) |
|
</code> |
|
→ |
|
<code> |
|
una geometría de punto |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-close_line"><a href="#geometrygroup-close_line-idx"> |
|
función close_line |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a closed line string of the input line string by appending the first point to the end of the line, if it is not already closed. If the geometry is not a line string or multi line string then the result will be null. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
close_line |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de cadena de línea |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(close_line(geom_from_wkt('LINESTRING(0 0, 1 0, 1 1)'))) |
|
</code> |
|
→ |
|
<code> |
|
LineString (0 0, 1 0, 1 1, 0 0) |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(close_line(geom_from_wkt('LINESTRING(0 0, 1 0, 1 1, 0 0)'))) |
|
</code> |
|
→ |
|
<code> |
|
LineString (0 0, 1 0, 1 1, 0 0) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-closest_point"><a href="#geometrygroup-closest_point-idx"> |
|
función closest_point |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the point on geometry1 that is closest to geometry2. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
closest_point |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry1 |
|
</td> |
|
<td> |
|
geometría en la que encontrar el punto más cercano |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry2 |
|
</td> |
|
<td> |
|
geometría a la que encontrar el punto más cercano |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(closest_point(geom_from_wkt('LINESTRING (20 80, 98 190, 110 180, 50 75 )'),geom_from_wkt('POINT(100 100)'))) |
|
</code> |
|
→ |
|
<code> |
|
Point(73.0769 115.384) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-collect_geometries"><a href="#geometrygroup-collect_geometries-idx"> |
|
función collect_geometries |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Collects a set of geometries into a multi-part geometry object. |
|
</p> |
|
</div> |
|
<h3 id="geometrygroup-collect_geometries"><a href="#geometrygroup-collect_geometries-idx"> |
|
List of arguments variant |
|
</a></h3> |
|
<div class="description"> |
|
Geometry parts are specified as separate arguments to the function. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
collect_geometries |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(collect_geometries(make_point(1,2), make_point(3,4), make_point(5,6))) |
|
</code> |
|
→ |
|
<code> |
|
'MultiPoint ((1 2),(3 4),(5 6))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="geometrygroup-collect_geometries"><a href="#geometrygroup-collect_geometries-idx"> |
|
Array variant |
|
</a></h3> |
|
<div class="description"> |
|
Geometry parts are specified as an array of geometry parts. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
collect_geometries |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
array of geometry objects |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(collect_geometries(array(make_point(1,2), make_point(3,4), make_point(5,6)))) |
|
</code> |
|
→ |
|
<code> |
|
'MultiPoint ((1 2),(3 4),(5 6))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-combine"><a href="#geometrygroup-combine-idx"> |
|
función combine |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la combinación de dos geometrías. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
combine |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry1 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry2 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( combine( geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 2 1)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
MULTILINESTRING((4 4, 2 1), (3 3, 4 4), (4 4, 5 5)) |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt( combine( geom_from_wkt( 'LINESTRING(3 3, 4 4)' ), geom_from_wkt( 'LINESTRING(3 3, 6 6, 2 1)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
LINESTRING(3 3, 4 4, 6 6, 2 1) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-contains"><a href="#geometrygroup-contains-idx"> |
|
función contains |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si una geometría contiene a otra. Devuelve verdadero si y solo si ningún punto de la geometría b cae en el exterior de la geometría a y al menos un punto del interior de b cae en el interior de a. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
contains |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
contains( geom_from_wkt( 'POLYGON((0 0, 0 1, 1 1, 1 0, 0 0))' ), geom_from_wkt( 'POINT(0.5 0.5 )' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
contains( geom_from_wkt( 'POLYGON((0 0, 0 1, 1 1, 1 0, 0 0))' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-convex_hull"><a href="#geometrygroup-convex_hull-idx"> |
|
función convex_hull |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la envolvente convexa de una geometría. Representa la geometría convexa mínima que encierra todas las geometrías del conjunto. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
convex_hull |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( convex_hull( geom_from_wkt( 'LINESTRING(3 3, 4 4, 4 10)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
POLYGON((3 3,4 10,4 4,3 3)) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-crosses"><a href="#geometrygroup-crosses-idx"> |
|
función crosses |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si una geometría cruza otra. Devuelve verdadero si las geometrías proporcionadas tienen algún punto interior en común, pero no todos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
crosses |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
crosses( geom_from_wkt( 'LINESTRING(3 5, 4 4, 5 3)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
crosses( geom_from_wkt( 'POINT(4 5)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-difference"><a href="#geometrygroup-difference-idx"> |
|
función difference |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría que representa la parte de la geometría_a que no interseca con la geometría_b. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
difference |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry_a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry_b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry_a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry_b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( difference( geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
LINESTRING(4 4, 5 5) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-disjoint"><a href="#geometrygroup-disjoint-idx"> |
|
función disjoint |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si las geometría no se intersecan espacialmente. Devuelve verdadero si las geometrías no comparten ningún espacio en común. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
disjoint |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
disjoint( geom_from_wkt( 'POLYGON((0 0, 0 1, 1 1, 1 0, 0 0 ))' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
disjoint( geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ), geom_from_wkt( 'POINT(4 4)' )) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-distance"><a href="#geometrygroup-distance-idx"> |
|
función distance |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la distancia mínima (basada en la referencia espacial) entre dos geometrías en unidades proyectadas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
distance |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
distance( geom_from_wkt( 'POINT(4 4)' ), geom_from_wkt( 'POINT(4 8)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
4 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-distance_to_vertex"><a href="#geometrygroup-distance_to_vertex-idx"> |
|
función distance_to_vertex |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la distancia a lo largo de la geometría a un vértice especificado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
distance_to_vertex |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
vertex |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de cadena de línea |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
vertex |
|
</td> |
|
<td> |
|
vertex index, starting from 0; if the value is negative, the selected vertex index will be its total count minus the absolute value |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
distance_to_vertex(geometry:=geom_from_wkt('LineString(0 0, 10 0, 10 10)'),vertex:=1) |
|
</code> |
|
→ |
|
<code> |
|
10.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-end_point"><a href="#geometrygroup-end_point-idx"> |
|
función end_point |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el último nodo de una geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
end_point |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(end_point(geom_from_wkt('LINESTRING(4 0, 4 2, 0 2)'))) |
|
</code> |
|
→ |
|
<code> |
|
'Point (0 2)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-extend"><a href="#geometrygroup-extend-idx"> |
|
función extend |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Extiende el inicio y final de una geometría de cadena de líneas en una cantidad especificada. Las líneas se extienden usando el rumbo del primer y último segmentos de la línea. Las distancias están el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
extend |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
start_distance |
|
</span> |
|
, |
|
<span class="argument"> |
|
end_distance |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de (multi)cadena de líneas |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
start_distance |
|
</td> |
|
<td> |
|
distancia a extender el inicio de la línea |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
end_distance |
|
</td> |
|
<td> |
|
distancia a extender el final de la línea. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(extend(geom_from_wkt('LineString(0 0, 1 0, 1 1)'),1,2)) |
|
</code> |
|
→ |
|
<code> |
|
LineString (-1 0, 1 0, 1 3) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-exterior_ring"><a href="#geometrygroup-exterior_ring-idx"> |
|
función exterior_ring |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una cadena de línea que representa el anillo exterior de una geometría de tipo polígono. Si la geometría no es un polígono entonces el resultado será nulo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
exterior_ring |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría de polígono |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(exterior_ring(geom_from_wkt('POLYGON((-1 -1, 4 0, 4 2, 0 2, -1 -1),( 0.1 0.1, 0.1 0.2, 0.2 0.2, 0.2, 0.1, 0.1 0.1))'))) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (-1 -1, 4 0, 4 2, 0 2, -1 -1)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-extrude"><a href="#geometrygroup-extrude-idx"> |
|
función extrude |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una versión extruida de la geometría de entrada (multi)curva o (multi)línea, con una extensión especificada por X e Y. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
extrude |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
, |
|
<span class="argument"> |
|
x |
|
</span> |
|
, |
|
<span class="argument"> |
|
y |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría de polígono |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
x |
|
</td> |
|
<td> |
|
extensión X, valor numérico |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
y |
|
</td> |
|
<td> |
|
extensión Y, valor numérico |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
extrude(geom_from_wkt('LineString(1 2, 3 2, 4 3)'), 1, 2) |
|
</code> |
|
→ |
|
<code> |
|
Polygon ((1 2, 3 2, 4 3, 5 5, 4 4, 2 4, 1 2)) |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
extrude(geom_from_wkt('MultiLineString((1 2, 3 2), (4 3, 8 3)'), 1, 2) |
|
</code> |
|
→ |
|
<code> |
|
MultiPolygon (((1 2, 3 2, 4 4, 2 4, 1 2)),((4 3, 8 3, 9 5, 5 5, 4 3))) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-flip_coordinates"><a href="#geometrygroup-flip_coordinates-idx"> |
|
función flip_coordinates |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a copy of the geometry with the x and y coordinates swapped. Useful for repairing geometries which have had their latitude and longitude values reversed. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
flip_coordinates |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(flip_coordinates(make_point(1, 2))) |
|
</code> |
|
→ |
|
<code> |
|
Point (2 1) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-force_rhr"><a href="#geometrygroup-force_rhr-idx"> |
|
función force_rhr |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Forces a geometry to respect the Right-Hand-Rule, in which the area that is bounded by a polygon is to the right of the boundary. In particular, the exterior ring is oriented in a clockwise direction and the interior rings in a counter-clockwise direction. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
force_rhr |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
a geometry. Any non-polygon geometries are returned unchanged. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(force_rhr(geometry:=geom_from_wkt('POLYGON((-1 -1, 4 0, 4 2, 0 2, -1 -1))'))) |
|
</code> |
|
→ |
|
<code> |
|
Polygon ((-1 -1, 0 2, 4 2, 4 0, -1 -1)) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-geom_from_gml"><a href="#geometrygroup-geom_from_gml-idx"> |
|
función geom_from_gml |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría a partir de una representación GML de geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
geom_from_gml |
|
</span> |
|
( |
|
<span class="argument"> |
|
gml |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
gml |
|
</td> |
|
<td> |
|
Representación GML de una geometría como una cadena |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_from_gml('<gml:LineString srsName="EPSG:4326"><gml:coordinates>4,4 5,5 6,6</gml:coordinates></gml:LineString>') |
|
</code> |
|
→ |
|
<code> |
|
a line geometry object |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-geom_from_wkb"><a href="#geometrygroup-geom_from_wkb-idx"> |
|
función geom_from_wkb |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a geometry created from a Well-Known Binary (WKB) representation. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
geom_from_wkb |
|
</span> |
|
( |
|
<span class="argument"> |
|
binary |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
binary |
|
</td> |
|
<td> |
|
Well-Known Binary (WKB) representation of a geometry (as a binary blob) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_from_wkb( geom_to_wkb( make_point(4,5) ) ) |
|
</code> |
|
→ |
|
<code> |
|
a point geometry object |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-geom_from_wkt"><a href="#geometrygroup-geom_from_wkt-idx"> |
|
función geom_from_wkt |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría creada a partir de una representación WKT (Texto Bien Conocido). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
geom_from_wkt |
|
</span> |
|
( |
|
<span class="argument"> |
|
text |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
text |
|
</td> |
|
<td> |
|
Representación WKT (Texto Bien Conocido) de una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_from_wkt( 'POINT(4 5)' ) |
|
</code> |
|
→ |
|
<code> |
|
un objeto de geometría |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-geom_to_wkb"><a href="#geometrygroup-geom_to_wkb-idx"> |
|
función geom_to_wkb |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the Well-Known Binary (WKB) representation of a geometry |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
geom_to_wkb |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkb( $geometry ) |
|
</code> |
|
→ |
|
<code> |
|
binary blob containing a geometry object |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-geom_to_wkt"><a href="#geometrygroup-geom_to_wkt-idx"> |
|
función geom_to_wkt |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una representación WKT (Texto Bien Conocido) de la geometría sin metadatos SRID. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
geom_to_wkt |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
[, |
|
<span class="argument"> |
|
precision |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
precision |
|
</td> |
|
<td> |
|
numeric precision |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( $geometry ) |
|
</code> |
|
→ |
|
<code> |
|
PUNTO(6 50) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-geometry"><a href="#geometrygroup-geometry-idx"> |
|
función geometry |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la geometría de un objeto. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
geometry |
|
</span> |
|
( |
|
<span class="argument"> |
|
feature |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
feature |
|
</td> |
|
<td> |
|
un objeto espacial |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( geometry( get_feature( capa, campo, valor ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
'PUNTO(6 50)' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
intersects( $geometry, geometry( get_feature( capa, campo, valor ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-geometry_n"><a href="#geometrygroup-geometry_n-idx"> |
|
función geometry_n |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría específica a partir de una colección de geometrías o nulo si la geometría de entrada no es una colección. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
geometry_n |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
index |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
colección de geometrías |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
index |
|
</td> |
|
<td> |
|
índice de la geometría a devolver, donde 1 es la primera geometría de la colección |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(geometry_n(geom_from_wkt('GEOMETRYCOLLECTION(POINT(0 1), POINT(0 0), POINT(1 0), POINT(1 1))'),3)) |
|
</code> |
|
→ |
|
<code> |
|
'Point (1 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-hausdorff_distance"><a href="#geometrygroup-hausdorff_distance-idx"> |
|
función hausdorff_distance |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la distancia de Hausdorff entre dos geometrías. Esto es básicamente una medida de cómo de similares o diferentes son dos geometrías, con una distancia menor indicando geometrías más parecidas. |
|
<br/> |
|
La función se puede ejecutar con un argumento fracción de densificación opcional. Si no se especifica se usará una aproximación de la distancia estándar de Hausdorff. Esta aproximación es exacta o suficientemente aproximada para un gran subconjunto de casos útiles. Ejemplos de esto son: |
|
<br/> |
|
<br/> |
|
</p> |
|
<li> |
|
procesar la distancia entre cadenas de líneas que son aproximadamente paralelas entre sí y aproximadamente iguales en longitud. Esto ocurre en redes lineales coincidentes. |
|
</li> |
|
<li> |
|
Probar similitud de geometrías. |
|
</li> |
|
<br/> |
|
<br/> |
|
Si la aproximación predeterminada por este método es insuficiente, especifique el argumento opcional fracción de densificación. Al especificar este argumento se realiza una densificación de segmentos antes de procesar la distancia discreta de Hausdorff. El parámetro establece la fracción por la que densificar cada segmento. Cada segmento se dividirá en un número de subsegmentos de igual longitud, cuya fracción de la longitud total es la más cercana a la fracción dada. Disminuir el parámetro fracción de densificación hará que la distancia devuelta se aproxime a la distancia de Hausdorff verdadera para las geometrías. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
hausdorff_distance |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
[, |
|
<span class="argument"> |
|
densify_fraction |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
densify_fraction |
|
</td> |
|
<td> |
|
Densificar la cantidad de fracciones |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
hausdorff_distance( geometry1:= geom_from_wkt('LINESTRING (0 0, 2 1)'),geometry2:=geom_from_wkt('LINESTRING (0 0, 2 0)')) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hausdorff_distance( geom_from_wkt('LINESTRING (130 0, 0 0, 0 150)'),geom_from_wkt('LINESTRING (10 10, 10 150, 130 10)')) |
|
</code> |
|
→ |
|
<code> |
|
14.142135623 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
hausdorff_distance( geom_from_wkt('LINESTRING (130 0, 0 0, 0 150)'),geom_from_wkt('LINESTRING (10 10, 10 150, 130 10)'),0.5) |
|
</code> |
|
→ |
|
<code> |
|
70.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-inclination"><a href="#geometrygroup-inclination-idx"> |
|
función inclination |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la inclinación medida desde el cénit (0) al nadir (180) en el punto A al punto B. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
inclination |
|
</span> |
|
( |
|
<span class="argument"> |
|
point_a |
|
</span> |
|
, |
|
<span class="argument"> |
|
point_b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point_a |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point_b |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 5, 10, 5 ) ) |
|
</code> |
|
→ |
|
<code> |
|
0.0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 5, 10, 0 ) ) |
|
</code> |
|
→ |
|
<code> |
|
90.0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 50, 100, 0 ) ) |
|
</code> |
|
→ |
|
<code> |
|
90.0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 5, 10, -5 ) ) |
|
</code> |
|
→ |
|
<code> |
|
180.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-interior_ring_n"><a href="#geometrygroup-interior_ring_n-idx"> |
|
función interior_ring_n |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un anillo interior específico de una geometría de tipo polígono o nulo si la geometría no es un polígono. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
interior_ring_n |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
index |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
geometría de tipo polígono |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
index |
|
</td> |
|
<td> |
|
índice del interior a devolver, donde 1 es el primer anillo interior |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(interior_ring_n(geom_from_wkt('POLYGON((-1 -1, 4 0, 4 2, 0 2, -1 -1),(-0.1 -0.1, 0.4 0, 0.4 0.2, 0 0.2, -0.1 -0.1),(-1 -1, 4 0, 4 2, 0 2, -1 -1))'),1)) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (-0.1 -0.1, 0.4 0, 0.4 0.2, 0 0.2, -0.1 -0.1))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-intersection"><a href="#geometrygroup-intersection-idx"> |
|
función intersection |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría que representa la parte compartida de dos geometrías. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
intersection |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry1 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry2 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( intersection( geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
LINESTRING(3 3, 4 4) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-intersects"><a href="#geometrygroup-intersects-idx"> |
|
función intersects |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si una geometría se interseca con otra. Devuelve verdadero si las geometrías se intersecan espacialmente (comparten alguna porción de espacio) y falso en caso contrario. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
intersects |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
intersects( geom_from_wkt( 'POINT(4 4)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
intersects( geom_from_wkt( 'POINT(4 5)' ), geom_from_wkt( 'POINT(5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-intersects_bbox"><a href="#geometrygroup-intersects_bbox-idx"> |
|
función intersects_bbox |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si el recuadro delimitador de una geometría solapa con el de otra geometría. Devuelve verdadero si los recuadros delimitadores de las geometrías se intersecan espacialmente y falso en caso contrario. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
intersects_bbox |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
intersects_bbox( geom_from_wkt( 'POINT(4 5)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
intersects_bbox( geom_from_wkt( 'POINT(6 5)' ), geom_from_wkt( 'POLYGON((3 3, 4 4, 5 5, 3 3))' ) ) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-is_closed"><a href="#geometrygroup-is_closed-idx"> |
|
función is_closed |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve verdadero si una cadena de línea está cerrada (los puntos de inicio y final coinciden) o falso si la cadena de línea no está cerrada. Si la geometría no es una cadena de línea entonces el resultado será nulo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_closed |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría de cadena de línea |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_closed(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2)')) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_closed(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2, 0 0)')) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-is_empty"><a href="#geometrygroup-is_empty-idx"> |
|
función is_empty |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if a geometry is empty (without coordinates), false if the geometry is not empty and NULL if there is no geometry. See also `is_empty_or_null`. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_empty |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_empty(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2)')) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_empty(geom_from_wkt('LINESTRING EMPTY')) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_empty(geom_from_wkt('POINT(7 4)')) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_empty(geom_from_wkt('POINT EMPTY')) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-is_empty_or_null"><a href="#geometrygroup-is_empty_or_null-idx"> |
|
función is_empty_or_null |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if a geometry is NULL or empty (without coordinates) or false otherwise. This function is like the expression '$geometry IS NULL or is_empty($geometry)' |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_empty_or_null |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_empty_or_null(NULL) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_empty_or_null(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2)')) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_empty_or_null(geom_from_wkt('LINESTRING EMPTY')) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_empty_or_null(geom_from_wkt('POINT(7 4)')) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_empty_or_null(geom_from_wkt('POINT EMPTY')) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-is_multipart"><a href="#geometrygroup-is_multipart-idx"> |
|
función is_multipart |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if the geometry is of Multi type. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_multipart |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_multipart(geom_from_wkt('MULTIPOINT ((0 0),(1 1),(2 2))')) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_multipart(geom_from_wkt('POINT (0 0)')) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-is_valid"><a href="#geometrygroup-is_valid-idx"> |
|
función is_valid |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns true if a geometry is valid; if it is well-formed in 2D according to the OGC rules. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_valid |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_valid(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2, 0 0)')) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
is_valid(geom_from_wkt('LINESTRING(0 0)')) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-length"><a href="#geometrygroup-length-idx"> |
|
función length |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el número de caracteres de una cadena o la longitud de la cadena que define una geometría. |
|
</p> |
|
</div> |
|
<h3 id="geometrygroup-length"><a href="#geometrygroup-length-idx"> |
|
Variante de cadena |
|
</a></h3> |
|
<div class="description"> |
|
Devuelve el número de caracteres de una cadena. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
length |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
cadena de la que medir la longitud |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
length('hola') |
|
</code> |
|
→ |
|
<code> |
|
5 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="geometrygroup-length"><a href="#geometrygroup-length-idx"> |
|
Variante de geometría |
|
</a></h3> |
|
<div class="description"> |
|
Calcula la longitud de un objeto de geometría lineal. Los cálculos siempre son planimétricos en el Sistema de Rerefencia Espacial (SRE) de esta geometría y las unidades de la longitud devuelta coincidirán con las unidades del SRE. Esto difiere de los cálculos hechos por la función $lenght, que hará cálculos elipsoidales basados en el elipsoide del proyecto y la configuración de las unidades de longitud. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
length |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría lineal |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
length(geom_from_wkt('LINESTRING(0 0, 4 0)')) |
|
</code> |
|
→ |
|
<code> |
|
4.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-line_interpolate_angle"><a href="#geometrygroup-line_interpolate_angle-idx"> |
|
función line_interpolate_angle |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el ángulo paralelo a la geometría a una distancia especificada a lo largo de una geometría cadena de líneas (linestring). Los ángulos están en grados en sentido horario desde el Norte. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
line_interpolate_angle |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
distance |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de cadena de línea |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
distance |
|
</td> |
|
<td> |
|
distancia a lo largo de la línea a la que interpolar el ángulo |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
line_interpolate_angle(geometry:=geom_from_wkt('LineString(0 0, 10 0)'),distance:=5) |
|
</code> |
|
→ |
|
<code> |
|
90.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-line_interpolate_point"><a href="#geometrygroup-line_interpolate_point-idx"> |
|
función line_interpolate_point |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el punto interpolado a una distancia especificada a lo largo de una geometría cadena de líneas (linestring). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
line_interpolate_point |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
distance |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de cadena de línea |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
distance |
|
</td> |
|
<td> |
|
distancia a lo largo de la línea a la que interpolar |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(line_interpolate_point(geometry:=geom_from_wkt('LineString(0 0, 10 0)'),distance:=5)) |
|
</code> |
|
→ |
|
<code> |
|
'Point (5 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-line_locate_point"><a href="#geometrygroup-line_locate_point-idx"> |
|
función line_locate_point |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la distancia a lo largo de un cadena de líneas que corresponde a la posición más cercana a la que llega la línea de una geometría de punto especificada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
line_locate_point |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
point |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de cadena de línea |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point |
|
</td> |
|
<td> |
|
geometría de punto a la que encontrar la posición más cercana desde la cadena de líneas |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
line_locate_point(geometry:=geom_from_wkt('LineString(0 0, 10 0)'),point:=geom_from_wkt('Point(5 0)')) |
|
</code> |
|
→ |
|
<code> |
|
5.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-line_merge"><a href="#geometrygroup-line_merge-idx"> |
|
función line_merge |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una cadena de líneas o multicadena de líneas en la que cualquier cadena de líneas conectada desde la geometría de entrada se ha combinado en una única cadena de líneas. Esta función devolverá nulo si se pasa una geometría que no es una cadena de líneas/multicadena de líneas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
line_merge |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría cadena de líneas/multicadena de líneas |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(line_merge(geom_from_wkt('MULTILINESTRING((0 0, 1 1),(1 1, 2 2))'))) |
|
</code> |
|
→ |
|
<code> |
|
'LineString(0 0,1 1,2 2)' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(line_merge(geom_from_wkt('MULTILINESTRING((0 0, 1 1),(11 1, 21 2))'))) |
|
</code> |
|
→ |
|
<code> |
|
'MultiLineString((0 0, 1 1),(11 1, 21 2)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-line_substring"><a href="#geometrygroup-line_substring-idx"> |
|
función line_substring |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the portion of a line (or curve) geometry which falls between the specified start and end distances (measured from the beginning of the line). Z and M values are linearly interpolated from existing values. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
line_substring |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
start_distance |
|
</span> |
|
, |
|
<span class="argument"> |
|
end_distance |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
a linestring or curve geometry |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
start_distance |
|
</td> |
|
<td> |
|
distancia al inicio de la subcadena |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
end_distance |
|
</td> |
|
<td> |
|
distancia al final de la subcadena |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(line_substring(geometry:=geom_from_wkt('LineString(0 0, 10 0)'),start_distance:=2,end_distance=6)) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (2 0,6 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-m"><a href="#geometrygroup-m-idx"> |
|
función m |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor m de una geometría de punto. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
m |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
m( geom_from_wkt( 'POINTM(2 5 4)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
4 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-m_max"><a href="#geometrygroup-m_max-idx"> |
|
función m_max |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the maximum m (measure) value of a geometry. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
m_max |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
a geometry containing m values |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
m_max( make_point_m( 0,0,1 ) ) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
m_max(make_line( make_point_m( 0,0,1 ), make_point_m( -1,-1,2 ), make_point_m( -2,-2,0 ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-m_min"><a href="#geometrygroup-m_min-idx"> |
|
función m_min |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the minimum m (measure) value of a geometry. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
m_min |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
a geometry containing m values |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
m_min( make_point_m( 0,0,1 ) ) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
m_min(make_line( make_point_m( 0,0,1 ), make_point_m( -1,-1,2 ), make_point_m( -2,-2,0 ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_circle"><a href="#geometrygroup-make_circle-idx"> |
|
función make_circle |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea un polígono circular. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_circle |
|
</span> |
|
( |
|
<span class="argument"> |
|
center |
|
</span> |
|
, |
|
<span class="argument"> |
|
radius |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segment=36 |
|
</span> |
|
]…) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
center |
|
</td> |
|
<td> |
|
punto centro del círculo |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
radius |
|
</td> |
|
<td> |
|
radio del círculo |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segment |
|
</td> |
|
<td> |
|
argumento opcional para la segmentación de polígonos. Por omisión, este valor es 36. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_circle(make_point(10,10), 5, 4)) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((10 15, 15 10, 10 5, 5 10, 10 15))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_circle(make_point(10,10,5), 5, 4)) |
|
</code> |
|
→ |
|
<code> |
|
'PolygonZ ((10 15 5, 15 10 5, 10 5 5, 5 10 5, 10 15 5))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_circle(make_point(10,10,5,30), 5, 4)) |
|
</code> |
|
→ |
|
<code> |
|
'PolygonZM ((10 15 5 30, 15 10 5 30, 10 5 5 30, 5 10 5 30, 10 15 5 30))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_ellipse"><a href="#geometrygroup-make_ellipse-idx"> |
|
función make_ellipse |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea un polígono elíptico. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_ellipse |
|
</span> |
|
( |
|
<span class="argument"> |
|
center |
|
</span> |
|
, |
|
<span class="argument"> |
|
semi_major_axis |
|
</span> |
|
, |
|
<span class="argument"> |
|
semi_minor_axis |
|
</span> |
|
, |
|
<span class="argument"> |
|
azimuth |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segment=36 |
|
</span> |
|
]…) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
center |
|
</td> |
|
<td> |
|
punto centro de la elipse |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
semi_major_axis |
|
</td> |
|
<td> |
|
semieje mayor de la elipse |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
semi_minor_axis |
|
</td> |
|
<td> |
|
semieje menor de la elipse |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
azimuth |
|
</td> |
|
<td> |
|
orientación de la elipse |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segment |
|
</td> |
|
<td> |
|
argumento opcional para la segmentación de polígonos. Por omisión, este valor es 36. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_ellipse(make_point(10,10), 5, 2, 90, 4)) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((15 10, 10 8, 5 10, 10 12, 15 10))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_ellipse(make_point(10,10,5), 5, 2, 90, 4)) |
|
</code> |
|
→ |
|
<code> |
|
'PolygonZ ((15 10 5, 10 8 5, 5 10 5, 10 12 5, 15 10 5))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_ellipse(make_point(10,10,5,30), 5, 2, 90, 4)) |
|
</code> |
|
→ |
|
<code> |
|
'PolygonZM ((15 10 5 30, 10 8 5 30, 5 10 5 30, 10 12 5 30, 15 10 5 30))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_line"><a href="#geometrygroup-make_line-idx"> |
|
función make_line |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea una geometría de línea a partir de una serie de geometrías de puntos. |
|
</p> |
|
</div> |
|
<h3 id="geometrygroup-make_line"><a href="#geometrygroup-make_line-idx"> |
|
List of arguments variant |
|
</a></h3> |
|
<div class="description"> |
|
Line vertices are specified as separate arguments to the function. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_line |
|
</span> |
|
( |
|
<span class="argument"> |
|
point1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
point2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point |
|
</td> |
|
<td> |
|
a point geometry (or array of points) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_line(make_point(2,4),make_point(3,5))) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (2 4, 3 5)' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_line(make_point(2,4),make_point(3,5),make_point(9,7))) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (2 4, 3 5, 9 7)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="geometrygroup-make_line"><a href="#geometrygroup-make_line-idx"> |
|
Array variant |
|
</a></h3> |
|
<div class="description"> |
|
Line vertices are specified as an array of points. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_line |
|
</span> |
|
( |
|
<span class="argument"> |
|
array |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
array |
|
</td> |
|
<td> |
|
array of points |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_line(array(make_point(2,4),make_point(3,5),make_point(9,7)))) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (2 4, 3 5, 9 7)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_point"><a href="#geometrygroup-make_point-idx"> |
|
función make_point |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea una geometría de punto a partir de unos valores de X e Y (y opcionalmente Z). |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_point |
|
</span> |
|
( |
|
<span class="argument"> |
|
x |
|
</span> |
|
, |
|
<span class="argument"> |
|
y |
|
</span> |
|
[, |
|
<span class="argument"> |
|
z |
|
</span> |
|
][, |
|
<span class="argument"> |
|
m |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
x |
|
</td> |
|
<td> |
|
Coordenada X del punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
y |
|
</td> |
|
<td> |
|
Coordenada Y del punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
z |
|
</td> |
|
<td> |
|
coordenada Z opcional del punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
m |
|
</td> |
|
<td> |
|
valor m opcional de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_point(2,4)) |
|
</code> |
|
→ |
|
<code> |
|
'Point (2 4)' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_point(2,4,6)) |
|
</code> |
|
→ |
|
<code> |
|
'PointZ (2 4 6)' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_point(2,4,6,8)) |
|
</code> |
|
→ |
|
<code> |
|
'PointZM (2 4 6 8)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_point_m"><a href="#geometrygroup-make_point_m-idx"> |
|
función make_point_m |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea una geometría de punto a partir de una coordenada X, Y y un valor m. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_point_m |
|
</span> |
|
( |
|
<span class="argument"> |
|
x |
|
</span> |
|
, |
|
<span class="argument"> |
|
y |
|
</span> |
|
, |
|
<span class="argument"> |
|
m |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
x |
|
</td> |
|
<td> |
|
Coordenada X del punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
y |
|
</td> |
|
<td> |
|
Coordenada Y del punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
m |
|
</td> |
|
<td> |
|
valor m de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_point_m(2,4,6)) |
|
</code> |
|
→ |
|
<code> |
|
'PointM (2 4 6)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_polygon"><a href="#geometrygroup-make_polygon-idx"> |
|
función make_polygon |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea una geometría de polígono a partir de un anillo exterior y series opcionales de geometrías interiores de anillo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_polygon |
|
</span> |
|
( |
|
<span class="argument"> |
|
outerRing |
|
</span> |
|
[, |
|
<span class="argument"> |
|
innerRing1 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
innerRing2 |
|
</span> |
|
]…) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
outerRing |
|
</td> |
|
<td> |
|
geometría de línea cerrada para anillo exterior del polígono |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
innerRing |
|
</td> |
|
<td> |
|
geometría de línea cerrada opcional para anillo interior |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_polygon(geom_from_wkt('LINESTRING( 0 0, 0 1, 1 1, 1 0, 0 0 )'))) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((0 0, 0 1, 1 1, 1 0, 0 0))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_polygon(geom_from_wkt('LINESTRING( 0 0, 0 1, 1 1, 1 0, 0 0 )'),geom_from_wkt('LINESTRING( 0.1 0.1, 0.1 0.2, 0.2 0.2, 0.2 0.1, 0.1 0.1 )'),geom_from_wkt('LINESTRING( 0.8 0.8, 0.8 0.9, 0.9 0.9, 0.9 0.8, 0.8 0.8 )'))) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((0 0, 0 1, 1 1, 1 0, 0 0),(0.1 0.1, 0.1 0.2, 0.2 0.2, 0.2 0.1, 0.1 0.1),(0.8 0.8, 0.8 0.9, 0.9 0.9, 0.9 0.8, 0.8 0.8))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_rectangle_3points"><a href="#geometrygroup-make_rectangle_3points-idx"> |
|
función make_rectangle_3points |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a rectangle from 3 points. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_rectangle_3points |
|
</span> |
|
( |
|
<span class="argument"> |
|
point1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
point2 |
|
</span> |
|
, |
|
<span class="argument"> |
|
point3 |
|
</span> |
|
[, |
|
<span class="argument"> |
|
option=0 |
|
</span> |
|
]…) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point1 |
|
</td> |
|
<td> |
|
Primer punto. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point2 |
|
</td> |
|
<td> |
|
Segundo punto. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point3 |
|
</td> |
|
<td> |
|
Tercer punto. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
option |
|
</td> |
|
<td> |
|
An optional argument to construct the rectangle. By default this value is 0. Value can be 0 (distance) or 1 (projected). Option distance: Second distance is equal to the distance between 2nd and 3rd point. Option projected: Second distance is equal to the distance of the perpendicular projection of the 3rd point on the segment or its extension. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_rectangle(make_point(0, 0), make_point(0,5), make_point(5, 5), 0))) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((0 0, 0 5, 5 5, 5 0, 0 0))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_rectangle(make_point(0, 0), make_point(0,5), make_point(5, 3), 1))) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((0 0, 0 5, 5 5, 5 0, 0 0))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_regular_polygon"><a href="#geometrygroup-make_regular_polygon-idx"> |
|
función make_regular_polygon |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea un polígono regular. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_regular_polygon |
|
</span> |
|
( |
|
<span class="argument"> |
|
center |
|
</span> |
|
, |
|
<span class="argument"> |
|
radius |
|
</span> |
|
, |
|
<span class="argument"> |
|
number_sides |
|
</span> |
|
[, |
|
<span class="argument"> |
|
circle=0 |
|
</span> |
|
]…) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
center |
|
</td> |
|
<td> |
|
centro del polígono regular |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
radius |
|
</td> |
|
<td> |
|
segundo punto. El primero si el polígono regular es inscrito. El punto central de la primera cara si el polígono regular es circunscrito. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
number_sides |
|
</td> |
|
<td> |
|
Número de caras/bordes del polígono regular |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
circle |
|
</td> |
|
<td> |
|
Argumento opcional para construir el polígono regular. Por omisión este valor es 0. El valor puede ser 0 (inscrito) o 1 (circunscrito). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_regular_polygon(make_point(0,0), make_point(0,5), 5)) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((0 5, 4.76 1.55, 2.94 -4.05, -2.94 -4.05, -4.76 1.55, 0 5))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_regular_polygon(make_point(0,0), project(make_point(0,0), 4.0451, radians(36)), 5)) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((0 5, 4.76 1.55, 2.94 -4.05, -2.94 -4.05, -4.76 1.55, 0 5))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_square"><a href="#geometrygroup-make_square-idx"> |
|
función make_square |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a square from a diagonal. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_square |
|
</span> |
|
( |
|
<span class="argument"> |
|
point1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
point2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point1 |
|
</td> |
|
<td> |
|
First point of the regular polygon |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point2 |
|
</td> |
|
<td> |
|
Segundo punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_square( make_point(0,0), make_point(5,5))) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((0 0, -0 5, 5 5, 5 0, 0 0))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_square( make_point(5,0), make_point(5,5))) |
|
</code> |
|
→ |
|
<code> |
|
'Polygon ((5 0, 2.5 2.5, 5 5, 7.5 2.5, 5 0))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-make_triangle"><a href="#geometrygroup-make_triangle-idx"> |
|
función make_triangle |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea un polígono triangular. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
make_triangle |
|
</span> |
|
( |
|
<span class="argument"> |
|
point 1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
point 2 |
|
</span> |
|
, |
|
<span class="argument"> |
|
point 3 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point 1 |
|
</td> |
|
<td> |
|
primer punto del triángulo |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point 2 |
|
</td> |
|
<td> |
|
segundo punto del triángulo |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point 3 |
|
</td> |
|
<td> |
|
tercer punto del triángulo |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(make_triangle(make_point(0,0), make_point(5,5), make_point(0,10))) |
|
</code> |
|
→ |
|
<code> |
|
'Triangle ((0 0, 5 5, 0 10, 0 0))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(boundary(make_triangle(make_point(0,0), make_point(5,5), make_point(0,10)))) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (0 0, 5 5, 0 10, 0 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-minimal_circle"><a href="#geometrygroup-minimal_circle-idx"> |
|
función minimal_circle |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el círculo envolvente mínimo de una geometría. Representa el círculo mínimo que encierra todas las geometrías del conjunto. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
minimal_circle |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segment=36 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segment |
|
</td> |
|
<td> |
|
argumento opcional para la segmentación de polígonos. Por omisión, este valor es 36. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( minimal_circle( geom_from_wkt( 'LINESTRING(0 5, 0 -5, 2 1)' ), 4 ) ) |
|
</code> |
|
→ |
|
<code> |
|
Polygon ((0 5, 5 -0, -0 -5, -5 0, 0 5)) |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt( minimal_circle( geom_from_wkt( 'MULTIPOINT(1 2, 3 4, 3 2)' ), 4 ) ) |
|
</code> |
|
→ |
|
<code> |
|
Polygon ((3 4, 3 2, 1 2, 1 4, 3 4)) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-nodes_to_points"><a href="#geometrygroup-nodes_to_points-idx"> |
|
función nodes_to_points |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría multipunto consistente en cada nodo de la geometría de entrada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
nodes_to_points |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
[, |
|
<span class="argument"> |
|
ignore_closing_nodes=false |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
ignore_closing_nodes |
|
</td> |
|
<td> |
|
argumento opcional que especifica si incluir nodos duplicados que cierran líneas o anillos de polígonos. El valor predeterminado es falso, establecer a verdadero para evitar incluir estos nodos duplicados en la colección de salida. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(nodes_to_points(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2)'))) |
|
</code> |
|
→ |
|
<code> |
|
'MultiPoint ((0 0),(1 1),(2 2))' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
geom_to_wkt(nodes_to_points(geom_from_wkt('POLYGON((-1 -1, 4 0, 4 2, 0 2, -1 -1))'),true)) |
|
</code> |
|
→ |
|
<code> |
|
'MultiPoint ((-1 -1),(4 0),(4 2),(0 2))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-num_geometries"><a href="#geometrygroup-num_geometries-idx"> |
|
función num_geometries |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el número de geometrías en una colección de geometrías o nulo si la geometría de entrada no es una colección. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
num_geometries |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
colección de geometrías |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
num_geometries(geom_from_wkt('GEOMETRYCOLLECTION(POINT(0 1), POINT(0 0), POINT(1 0), POINT(1 1))')) |
|
</code> |
|
→ |
|
<code> |
|
4 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-num_interior_rings"><a href="#geometrygroup-num_interior_rings-idx"> |
|
función num_interior_rings |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el número de anillos interiores de un polígono o una colección de geometrías o nulo si la geometría de entrada no es un polígono o una colección. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
num_interior_rings |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
geometría de entrada |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
num_interior_rings(geom_from_wkt('POLYGON((-1 -1, 4 0, 4 2, 0 2, -1 -1),(-0.1 -0.1, 0.4 0, 0.4 0.2, 0 0.2, -0.1 -0.1))')) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-num_points"><a href="#geometrygroup-num_points-idx"> |
|
función num_points |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el número de vértices de una geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
num_points |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
num_points($geometry) |
|
</code> |
|
→ |
|
<code> |
|
número de vértices en $geometry |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-num_rings"><a href="#geometrygroup-num_rings-idx"> |
|
función num_rings |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el número de anillos (incluidos los anillos exteriores) de un polígono o una colección de geometrías o nulo si la geometría de entrada no es un polígono o una colección. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
num_rings |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
geometría de entrada |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
num_rings(geom_from_wkt('POLYGON((-1 -1, 4 0, 4 2, 0 2, -1 -1),(-0.1 -0.1, 0.4 0, 0.4 0.2, 0 0.2, -0.1 -0.1))')) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-offset_curve"><a href="#geometrygroup-offset_curve-idx"> |
|
función offset_curve |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría formada desplazando una geometría de línea hacia un lado. Las distancias están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
offset_curve |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
distance |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segments=8 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
join=1 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
miter_limit=2.0 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de (multi)cadena de líneas |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
distance |
|
</td> |
|
<td> |
|
distancia de desplazamiento. Para valores positivos se hará un buffer a la izquierda de las líneas y para valores negativos para la derecha. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segments |
|
</td> |
|
<td> |
|
número de segmentos a usar para representar un cuarto de círculo cuando se utilice un estilo de unión redondo. Un número mayor da como resultado una línea más suave con más nodos. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
join |
|
</td> |
|
<td> |
|
estilo de unión para esquinas, donde 1 = redondo, 2 = inglete y 3 = bisel |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
miter_limit |
|
</td> |
|
<td> |
|
límite en el radio del inglete utilizado para esquinas muy agudas (solamente al utilizar uniones en inglete) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
offset_curve($geometry, 10.5) |
|
</code> |
|
→ |
|
<code> |
|
desplazamiento de línea a la izquierda en 10,5 unidades |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
offset_curve($geometry, -10.5) |
|
</code> |
|
→ |
|
<code> |
|
desplazamiento de línea a la derecha en 10,5 unidades |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
offset_curve($geometry, 10.5, segments=16, join=1) |
|
</code> |
|
→ |
|
<code> |
|
desplazamiento de línea a la izquierda en 10,5 unidades, usando más segmentos para obtener una curva más suave |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
offset_curve($geometry, 10.5, join=3) |
|
</code> |
|
→ |
|
<code> |
|
desplazamiento de línea a la izquierda por 10.5 unidades, usando una unión en bisel |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-order_parts"><a href="#geometrygroup-order_parts-idx"> |
|
función order_parts |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Ordena las partes de una MultiGeometría por los criterios dados |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
order_parts |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
, |
|
<span class="argument"> |
|
orderby |
|
</span> |
|
, |
|
<span class="argument"> |
|
ascending |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría multi tipo |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
orderby |
|
</td> |
|
<td> |
|
una cadena de expresión que define los criterios de ordenación |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
ascending |
|
</td> |
|
<td> |
|
lógico, Verdadero para ascendente, Falso para descendente |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
order_parts(geom_from_wkt('MultiPolygon (((1 1, 5 1, 5 5, 1 5, 1 1)),((1 1, 9 1, 9 9, 1 9, 1 1)))'), 'area($geometry)', False) |
|
</code> |
|
→ |
|
<code> |
|
MultiPolygon (((1 1, 9 1, 9 9, 1 9, 1 1)),((1 1, 5 1, 5 5, 1 5, 1 1))) |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
order_parts(geom_from_wkt('LineString(1 2, 3 2, 4 3)'), '1', True) |
|
</code> |
|
→ |
|
<code> |
|
LineString(1 2, 3 2, 4 3) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-oriented_bbox"><a href="#geometrygroup-oriented_bbox-idx"> |
|
función oriented_bbox |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría que representa el recuadro delimitador orientado mínimo de una geometría de entrada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
oriented_bbox |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( oriented_bbox( geom_from_wkt( 'MULTIPOINT(1 2, 3 4, 3 2)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
Polygon ((1 4, 1 2, 3 2, 3 4, 1 4)) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-overlaps"><a href="#geometrygroup-overlaps-idx"> |
|
función overlaps |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si una geometría solapa con otra. Devuelve verdadero si las geometrías comparten espacio, son de la misma dimensión, pero no están contenidas en la otra. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
overlaps |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
overlaps( geom_from_wkt( 'LINESTRING(3 5, 4 4, 5 5, 5 3)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
overlaps( geom_from_wkt( 'LINESTRING(0 0, 1 1)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-perimeter"><a href="#geometrygroup-perimeter-idx"> |
|
función perimeter |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el perímetro de un objeto de geometría de tipo polígono. Los cálculos siempre son planimétricos en el Sistema de Rerefencia Espacial (SRE) de esta geometría y las unidades del perímetro devuelto coincidirán con las unidades del SRE. Esto difiere de los cálculos hechos por la función $perimeter, que hará cálculos elipsoidales basados en el elipsoide del proyecto y la configuración de las unidades de distancia. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
perimeter |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría poligonal |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
perimeter(geom_from_wkt('POLYGON((0 0, 4 0, 4 2, 0 2, 0 0))')) |
|
</code> |
|
→ |
|
<code> |
|
12.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-point_n"><a href="#geometrygroup-point_n-idx"> |
|
función point_n |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un nodo específico de una geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
point_n |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
index |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
index |
|
</td> |
|
<td> |
|
index of node to return, where 1 is the first node; if the value is negative, the selected vertex index will be its total count minus the absolute value |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(point_n(geom_from_wkt('POLYGON((0 0, 4 0, 4 2, 0 2, 0 0))'),2)) |
|
</code> |
|
→ |
|
<code> |
|
'Point (4 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-point_on_surface"><a href="#geometrygroup-point_on_surface-idx"> |
|
función point_on_surface |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un punto garantizando que cae en la superficie de una geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
point_on_surface |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
point_on_surface($geometry) |
|
</code> |
|
→ |
|
<code> |
|
una geometría de punto |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-pole_of_inaccessibility"><a href="#geometrygroup-pole_of_inaccessibility-idx"> |
|
función pole_of_inaccessibility |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Calcula el polo aproximado de inaccesibilidad para una superficie, que es el punto interno de una superficie más distante del borde de la superficie. Esta función usa el algoritmo "polylabel" (Vladimir Agafonkin, 2016), que es una aproximación iterativa que garantiza encontrar el polo real de inaccesibilidad dentro de una tolerancia especificada. Tolerancias más precisas requieren más iteraciones y llevará más tiempo calcularlas. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
pole_of_inaccessibility |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
tolerance |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
tolerance |
|
</td> |
|
<td> |
|
distancia máxima entre el punto devuelto y la localización del polo verdadero |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(pole_of_inaccessibility( geom_from_wkt('POLYGON((0 1,0 9,3 10,3 3, 10 3, 10 1, 0 1))'), 0.1)) |
|
</code> |
|
→ |
|
<code> |
|
Point(1.55, 1.55) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-project"><a href="#geometrygroup-project-idx"> |
|
función project |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a point projected from a start point using a distance, a bearing (azimuth) and an elevation in radians. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
project |
|
</span> |
|
( |
|
<span class="argument"> |
|
point |
|
</span> |
|
, |
|
<span class="argument"> |
|
distance |
|
</span> |
|
, |
|
<span class="argument"> |
|
azimuth |
|
</span> |
|
[, |
|
<span class="argument"> |
|
elevation |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point |
|
</td> |
|
<td> |
|
punto de inicio |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
distance |
|
</td> |
|
<td> |
|
distancia a proyectar |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
azimuth |
|
</td> |
|
<td> |
|
azimuth in radians clockwise, where 0 corresponds to north |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
elevation |
|
</td> |
|
<td> |
|
angle of inclination in radians |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(project(make_point(1, 2), 3, radians(270))) |
|
</code> |
|
→ |
|
<code> |
|
Point(-2, 2) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-relate"><a href="#geometrygroup-relate-idx"> |
|
función relate |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Prueba la representación del Modelo de Intersección 9 Extendido Dimensional (DE-9IM) de la relación entre dos geometrías. |
|
</p> |
|
</div> |
|
<h3 id="geometrygroup-relate"><a href="#geometrygroup-relate-idx"> |
|
Variante de relación |
|
</a></h3> |
|
<div class="description"> |
|
Devuelve la representación del Modelo de Intersección 9 Extendido Dimensional (DE-9IM) de la relación entre dos geometrías. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
relate |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
relate( geom_from_wkt( 'LINESTRING(40 40,120 120)' ), geom_from_wkt( 'LINESTRING(40 40,60 120)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
'FF1F00102' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="geometrygroup-relate"><a href="#geometrygroup-relate-idx"> |
|
Variante de coincidencia de patrón |
|
</a></h3> |
|
<div class="description"> |
|
Prueba si la relación DE-9IM entre dos geometrías coincide con el patrón especificado. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
relate |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
pattern |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
pattern |
|
</td> |
|
<td> |
|
Patrón DE-9IM con el que coincidir |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
relate( geom_from_wkt( 'LINESTRING(40 40,120 120)' ), geom_from_wkt( 'LINESTRING(40 40,60 120)' ), '**1F001**' ) |
|
</code> |
|
→ |
|
<code> |
|
Verdadero |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-reverse"><a href="#geometrygroup-reverse-idx"> |
|
función reverse |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Cambia el sentido de una línea invirtiendo el orden de sus vértices. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
reverse |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(reverse(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2)'))) |
|
</code> |
|
→ |
|
<code> |
|
'LINESTRING(2 2, 1 1, 0 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-rotate"><a href="#geometrygroup-rotate-idx"> |
|
función rotate |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a rotated version of a geometry. Calculations are in the Spatial Reference System of this geometry. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
rotate |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
, |
|
<span class="argument"> |
|
rotation |
|
</span> |
|
[, |
|
<span class="argument"> |
|
point |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
rotation |
|
</td> |
|
<td> |
|
clockwise rotation in degrees |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point |
|
</td> |
|
<td> |
|
rotation center point. If not specified, the center of the geometry's bounding box is used. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
rotate($geometry, 45, make_point(4, 5)) |
|
</code> |
|
→ |
|
<code> |
|
geometry rotated 45 degrees clockwise around the (4, 5) point |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
rotate($geometry, 45) |
|
</code> |
|
→ |
|
<code> |
|
geometry rotated 45 degrees clockwise around the center of its bounding box |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-segments_to_lines"><a href="#geometrygroup-segments_to_lines-idx"> |
|
función segments_to_lines |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría multilínea que consiste en una línea para cada segmento de la geometría de entrada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
segments_to_lines |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(segments_to_lines(geom_from_wkt('LINESTRING(0 0, 1 1, 2 2)'))) |
|
</code> |
|
→ |
|
<code> |
|
'MultiLineString ((0 0, 1 1),(1 1, 2 2))' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-shortest_line"><a href="#geometrygroup-shortest_line-idx"> |
|
función shortest_line |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the shortest line joining geometry1 to geometry2. The resultant line will start at geometry1 and end at geometry2. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
shortest_line |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry1 |
|
</td> |
|
<td> |
|
geometría desde la que encontrar la línea más corta |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry2 |
|
</td> |
|
<td> |
|
geometría hasta la que encontrar la línea más corta |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(shortest_line(geom_from_wkt('LINESTRING (20 80, 98 190, 110 180, 50 75 )'),geom_from_wkt('POINT(100 100)'))) |
|
</code> |
|
→ |
|
<code> |
|
LineString(73.0769 115.384, 100 100) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-simplify"><a href="#geometrygroup-simplify-idx"> |
|
función simplify |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Simplifica una geometría eliminando nodos usando un margen basado en distancia (esto es, el algoritmo Douglas Peucker). El algoritmo conserva grandes desviaciones de las geometrías y reduce el número de vértices en segmentos prácticamente rectos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
simplify |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
tolerance |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
tolerance |
|
</td> |
|
<td> |
|
desviación máxima de segmentos rectos para eliminar puntos |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(simplify(geometry:=geom_from_wkt('LineString(0 0, 5 0.1, 10 0)'),tolerance:=5)) |
|
</code> |
|
→ |
|
<code> |
|
'LineString(0 0, 10 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-simplify_vw"><a href="#geometrygroup-simplify_vw-idx"> |
|
función simplify_vw |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Simplifica una geometría eliminando nodos usando un margen basado en área (esto es, el algoritmo Visvalingam-Whyatt). El algoritmo elimina vértices que crean pequeñas áreas en las geometrías, por ejemplo salientes estrechos o segmentos prácticamente rectos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
simplify_vw |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
tolerance |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
tolerance |
|
</td> |
|
<td> |
|
una medida del área máxima creada por un nodo para eliminar el nodo |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(simplify_vw(geometry:=geom_from_wkt('LineString(0 0, 5 0, 5.01 10, 5.02 0, 10 0)'),tolerance:=5)) |
|
</code> |
|
→ |
|
<code> |
|
'LineString(0 0, 10 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-single_sided_buffer"><a href="#geometrygroup-single_sided_buffer-idx"> |
|
función single_sided_buffer |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría formada haciendo un buffer de una geometría de línea hacia un lado. Las distancias están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
single_sided_buffer |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
distance |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segments=8 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
join=1 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
miter_limit=2.0 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría de (multi)cadena de líneas |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
distance |
|
</td> |
|
<td> |
|
distancia de buffer. Para valores positivos se hará un buffer a la izquierda de las líneas y para valores negativos a la derecha. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segments |
|
</td> |
|
<td> |
|
número de segmentos a usar para representar un cuarto de círculo cuando se utilice un estilo de unión redondo. Un número mayor da como resultado un buffer más suave con más nodos. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
join |
|
</td> |
|
<td> |
|
estilo de unión para esquinas, donde 1 = redondo, 2 = inglete y 3 = bisel |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
miter_limit |
|
</td> |
|
<td> |
|
límite en el radio del inglete utilizado para esquinas muy agudas (solamente al utilizar uniones en inglete) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
single_sided_buffer($geometry, 10.5) |
|
</code> |
|
→ |
|
<code> |
|
línea hecha buffer a la izquierda en 10,5 unidades |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
single_sided_buffer($geometry, -10.5) |
|
</code> |
|
→ |
|
<code> |
|
línea hecha buffer a la derecha en 10,5 unidades |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
single_sided_buffer($geometry, 10.5, segments=16, join=1) |
|
</code> |
|
→ |
|
<code> |
|
buffer de línea a la izquierda en 10.5 unidades, usando más segmentos para obtener un buffer más suabe. |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
single_sided_buffer($geometry, 10.5, join=3) |
|
</code> |
|
→ |
|
<code> |
|
línea hecha buffer a la izquierda por 10.5 unidades, usando una unión en bisel |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-smooth"><a href="#geometrygroup-smooth-idx"> |
|
función smooth |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Smooths a geometry by adding extra nodes which round off corners in the geometry. If input geometries contain Z or M values, these will also be smoothed and the output geometry will retain the same dimensionality as the input geometry. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
smooth |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
[, |
|
<span class="argument"> |
|
iterations |
|
</span> |
|
][, |
|
<span class="argument"> |
|
offset |
|
</span> |
|
][, |
|
<span class="argument"> |
|
min_length |
|
</span> |
|
][, |
|
<span class="argument"> |
|
max_angle |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
iterations |
|
</td> |
|
<td> |
|
número de iteraciones de suavizado a aplicar. Números grandes dan lugar a geometrías más suaves, pero más complejas. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
offset |
|
</td> |
|
<td> |
|
valor entre 0 y 0,5 que controla hasta qué punto se ajusta la geometría suavizada a la original. Número pequeños dan lugar a un suavizado más ajustado, mientras que números mayores dan lugar a un ajustado más laxo. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
min_length |
|
</td> |
|
<td> |
|
longitud mínima de segmento a la que aplicar el suavizado. Este parámetro se puede usar para evitar colocar un número excesivo de nodos adicionales en los segmentos más cortos de la geometría. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
max_angle |
|
</td> |
|
<td> |
|
ángulo máximo en el nodo para aplicar suavizado (0-180). Disminuyendo el ángulo máximo se pueden conservar esquinas intencionadamente agudas de la geometría. Por ejemplo, un valor de 80 grados conservará los ángulos rectos de la geometría. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(smooth(geometry:=geom_from_wkt('LineString(0 0, 5 0, 5 5)'),iterations:=1,offset:=0.2,min_length:=-1,max_angle:=180)) |
|
</code> |
|
→ |
|
<code> |
|
'LineString (0 0, 4 0, 5 1, 5 5)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-start_point"><a href="#geometrygroup-start_point-idx"> |
|
función start_point |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el primer nodo de una geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
start_point |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
objeto de geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt(start_point(geom_from_wkt('LINESTRING(4 0, 4 2, 0 2)'))) |
|
</code> |
|
→ |
|
<code> |
|
'Point (4 0)' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-sym_difference"><a href="#geometrygroup-sym_difference-idx"> |
|
función sym_difference |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría que representa las partes de dos geometrías que no se intersecan. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
sym_difference |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry1 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry2 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( sym_difference( geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ), geom_from_wkt( 'LINESTRING(3 3, 8 8)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
LINESTRING(5 5, 8 8) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-tapered_buffer"><a href="#geometrygroup-tapered_buffer-idx"> |
|
función tapered_buffer |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crea un búfer a lo largo de una geometría lineal donde el diámetro del búfer varía uniformemente sobre la longitud de la línea. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
tapered_buffer |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
, |
|
<span class="argument"> |
|
start_width |
|
</span> |
|
, |
|
<span class="argument"> |
|
end_width |
|
</span> |
|
[, |
|
<span class="argument"> |
|
segments=8 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
geometría de entrada. Debe ser una geometría de (varias) líneas. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
start_width |
|
</td> |
|
<td> |
|
ancho del búfer al inicio de la línea, |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
end_width |
|
</td> |
|
<td> |
|
ancho del búfer al final de la línea. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
segments |
|
</td> |
|
<td> |
|
número de segmentos para aproximar las curvas del un cuarto de círculo en el buffer. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
tapered_buffer(geometry:=geom_from_wkt('LINESTRING(1 2, 4 2)'),start_width:=1,end_width:=2,segments:=8) |
|
</code> |
|
→ |
|
<code> |
|
Un búfer estrechado comenzando con un diámetro de 1 y terminando con un diámetro de 2 a lo largo de una geometría de cadena de líneas. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-touches"><a href="#geometrygroup-touches-idx"> |
|
función touches |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si una geometría toca a otra. Devuelve verdadero si las geometrías tienen al menos un punto en común, pero sus interiores no se intersecan. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
touches |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
touches( geom_from_wkt( 'LINESTRING(5 3, 4 4)' ), geom_from_wkt( 'LINESTRING(3 3, 4 4, 5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
touches( geom_from_wkt( 'POINT(4 4)' ), geom_from_wkt( 'POINT(5 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-transform"><a href="#geometrygroup-transform-idx"> |
|
función transform |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la geometría transformada desde un SRC de origen a otro de destino. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
transform |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
, |
|
<span class="argument"> |
|
source_auth_id |
|
</span> |
|
, |
|
<span class="argument"> |
|
dest_auth_id |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
source_auth_id |
|
</td> |
|
<td> |
|
ID del SRC de origen |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
dest_auth_id |
|
</td> |
|
<td> |
|
ID del SRC de destino |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( transform( $geometry, 'EPSG:2154', 'EPSG:4326' ) ) |
|
</code> |
|
→ |
|
<code> |
|
POINT(0 51) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-translate"><a href="#geometrygroup-translate-idx"> |
|
función translate |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una versión convertida de una geometría. Los cálculos se hacen en el Sistema de Referencia Espacial de la geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
translate |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
, |
|
<span class="argument"> |
|
dx |
|
</span> |
|
, |
|
<span class="argument"> |
|
dy |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
dx |
|
</td> |
|
<td> |
|
delta x |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
dy |
|
</td> |
|
<td> |
|
delta y |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
convertir($geometría,5,10) |
|
</code> |
|
→ |
|
<code> |
|
una geometría del mismo tipo que la original |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-union"><a href="#geometrygroup-union-idx"> |
|
función union |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve una geometría que representa el conjunto unión de los puntos de las geometrías. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
union |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry2 |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry1 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry2 |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
geom_to_wkt( union( geom_from_wkt( 'POINT(4 4)' ), geom_from_wkt( 'POINT(5 5)' ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
MULTIPOINT(4 4, 5 5) |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-wedge_buffer"><a href="#geometrygroup-wedge_buffer-idx"> |
|
función wedge_buffer |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Regresa un búfer en forma de cuña originado de una geometría de punto. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
wedge_buffer |
|
</span> |
|
( |
|
<span class="argument"> |
|
center |
|
</span> |
|
, |
|
<span class="argument"> |
|
azimuth |
|
</span> |
|
, |
|
<span class="argument"> |
|
width |
|
</span> |
|
, |
|
<span class="argument"> |
|
outer_radius |
|
</span> |
|
[, |
|
<span class="argument"> |
|
inner_radius=0.0 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
center |
|
</td> |
|
<td> |
|
punto central (origen) del buffer. Debe ser una geometría de punto. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
azimuth |
|
</td> |
|
<td> |
|
ángulo (en grados) desde la mitad de la cuña a un punto. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
width |
|
</td> |
|
<td> |
|
ancho de búfer (en grados). Note que la cuña se extenderá a la mitad de la anchura angular por ambos lados en la dirección azimutal. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
outer_radius |
|
</td> |
|
<td> |
|
radio exterior para los buffers |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
inner_radius |
|
</td> |
|
<td> |
|
radio interno opcional para buffers |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
wedge_buffer(center:=geom_from_wkt('POINT(1 2)'),azimuth:=90,width:=180,outer_radius:=1) |
|
</code> |
|
→ |
|
<code> |
|
Un búfer en forma de cuña centrado en el punto (1,2), apuntando hacia el Este, con un ancho de 180 grados y radio externo de 1. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-within"><a href="#geometrygroup-within-idx"> |
|
función within |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Comprueba si una geometría está dentro de otra. Devuelve verdadero si la geometría a está completamente dentro de la geometría b. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
within |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry a |
|
</span> |
|
, |
|
<span class="argument"> |
|
geometry b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry a |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
geometry b |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
within( geom_from_wkt( 'POINT( 0.5 0.5)' ), geom_from_wkt( 'POLYGON((0 0, 0 1, 1 1, 1 0, 0 0))' ) ) |
|
</code> |
|
→ |
|
<code> |
|
verdadero |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
within( geom_from_wkt( 'POINT( 5 5 )' ), geom_from_wkt( 'POLYGON((0 0, 0 1, 1 1, 1 0, 0 0 ))' ) ) |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-x"><a href="#geometrygroup-x-idx"> |
|
función x |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada X de una geometría de tipo punto o la coordenada X del centroide de una geometría que no sea de puntos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
x |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
x( geom_from_wkt( 'POINT(2 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
x( $geometría) |
|
</code> |
|
→ |
|
<code> |
|
coordenada X del centroide del objeto actual |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-x_max"><a href="#geometrygroup-x_max-idx"> |
|
función x_max |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada X máxima de una geometría. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
x_max |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
x_max( geom_from_wkt( 'LINESTRING(2 5, 3 6, 4 8)') ) |
|
</code> |
|
→ |
|
<code> |
|
4 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-x_min"><a href="#geometrygroup-x_min-idx"> |
|
función x_min |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada X mínima de una geometría. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
x_min |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
x_min( geom_from_wkt( 'LINESTRING(2 5, 3 6, 4 8)') ) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-y"><a href="#geometrygroup-y-idx"> |
|
función y |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada Y de una geometría de tipo punto o la coordenada Y del centroide de una geometría que no sea de puntos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
y |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
y( geom_from_wkt( 'POINT(2 5)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
5 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
y( $geometría ) |
|
</code> |
|
→ |
|
<code> |
|
coordenada Y del centroide del objeto actual |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-y_max"><a href="#geometrygroup-y_max-idx"> |
|
función y_max |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada Y máxima de una geometría. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
y_max |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
y_max( geom_from_wkt( 'LINESTRING(2 5, 3 6, 4 8)') ) |
|
</code> |
|
→ |
|
<code> |
|
8 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-y_min"><a href="#geometrygroup-y_min-idx"> |
|
función y_min |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada Y mínima de una geometría. Los cálculos están en el Sistema de Referencia Espacial de esta geometría. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
y_min |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
y_min( geom_from_wkt( 'LINESTRING(2 5, 3 6, 4 8)') ) |
|
</code> |
|
→ |
|
<code> |
|
5 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-z"><a href="#geometrygroup-z-idx"> |
|
función z |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la coordenada Z de una geometría de punto. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
z |
|
</span> |
|
( |
|
<span class="argument"> |
|
geom |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geom |
|
</td> |
|
<td> |
|
una geometría de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
z( geom_from_wkt( 'POINTZ(2 5 7)' ) ) |
|
</code> |
|
→ |
|
<code> |
|
7 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-z_max"><a href="#geometrygroup-z_max-idx"> |
|
función z_max |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the maximum z coordinate of a geometry. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
z_max |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
a geometry with z coordinate |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
z_max( geom_from_wkt( 'POINT ( 0 0 1 )' ) ) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
z_max( make_line( make_point( 0,0,0 ), make_point( -1,-1,-2 ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="geometrygroup-z_min"><a href="#geometrygroup-z_min-idx"> |
|
función z_min |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the minimum z coordinate of a geometry. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
z_min |
|
</span> |
|
( |
|
<span class="argument"> |
|
geometry |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
geometry |
|
</td> |
|
<td> |
|
a geometry with z coordinate |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
z_min( geom_from_wkt( 'POINT ( 0 0 1 )' ) ) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
z_min( make_line( make_point( 0,0,0 ), make_point( -1,-1,-2 ) ) ) |
|
</code> |
|
→ |
|
<code> |
|
-2 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="layout" class="group">falta la ayuda de la función para Layout</div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="layout-item_variables"><a href="#layout-item_variables-idx"> |
|
función item_variables |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un mapa de variables a partir de un elemento del diseñador dentro de esta composición. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
item_variables |
|
</span> |
|
( |
|
<span class="argument"> |
|
id |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
id |
|
</td> |
|
<td> |
|
ID del elemento del diseñador |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_get(item_variables('mapa_principal'), 'escala_de_mapa') |
|
</code> |
|
→ |
|
<code> |
|
2000 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="map-layers" class="group"><h2><a href="#map-layers-idx">grupo capas de mapa</a></h2> |
|
<div class="description"><p>Contiene una lista de capas de mapa disponibles en el proyecto actual.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="map-layers-decode_uri"><a href="#map-layers-decode_uri-idx"> |
|
función decode_uri |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Takes a layer and decodes the uri of the underlying data provider. It depends on the dataprovider, which data is available. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
decode_uri |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
[, |
|
<span class="argument"> |
|
part |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
The layer for which the uri should be decoded. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
part |
|
</td> |
|
<td> |
|
The part of the uri to return. If unspecified, a map with all uri parts will be returned. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
decode_uri(@layer) |
|
</code> |
|
→ |
|
<code> |
|
{'layerId': '0', 'layerName': '', 'path': '/home/qgis/shapefile.shp'} |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
decode_uri(@layer) |
|
</code> |
|
→ |
|
<code> |
|
{'layerId': NULL, 'layerName': 'layer', 'path': '/home/qgis/geopackage.gpkg'} |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
decode_uri(@layer, 'path') |
|
</code> |
|
→ |
|
<code> |
|
'C:\my_data\qgis\shape.shp' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="maps" class="group"><h2><a href="#maps-idx">grupo mapas</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones de expresiones para la creación y manipulación de estructuras de datos de "mapa" (también conocidos como objetos de diccionario, pares clave-valor o matrices asociativas). Se pueden asignar valores a las claves dadas. El orden de los pares clave-valor en el objeto de mapa es irrelevante.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-from_json"><a href="#maps-from_json-idx"> |
|
función from_json |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Loads a JSON formatted string. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
from_json |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
JSON texto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
from_json('{"qgis":"rocks"}') |
|
</code> |
|
→ |
|
<code> |
|
{ "qgis" : "rocks" } |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
from_json('[1,2,3]') |
|
</code> |
|
→ |
|
<code> |
|
[1,2,3] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-hstore_to_map"><a href="#maps-hstore_to_map-idx"> |
|
función hstore_to_map |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a map from a hstore-formatted string. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
hstore_to_map |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
la cadena de entrada |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
hstore_to_map('qgis=>rocks') |
|
</code> |
|
→ |
|
<code> |
|
{ "qgis" : "rocks" } |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-json_to_map"><a href="#maps-json_to_map-idx"> |
|
función json_to_map |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Creates a map from a json-formatted string. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
json_to_map |
|
</span> |
|
( |
|
<span class="argument"> |
|
string |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
string |
|
</td> |
|
<td> |
|
la cadena de entrada |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
json_to_map('{"qgis":"rocks"}') |
|
</code> |
|
→ |
|
<code> |
|
{ "qgis" : "rocks" } |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map"><a href="#maps-map-idx"> |
|
función map |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un mapa que contiene todas las claves y valores pasados como pares de parámetros. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map |
|
</span> |
|
( |
|
<span class="argument"> |
|
key1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
value1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
key2 |
|
</span> |
|
, |
|
<span class="argument"> |
|
value2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
key |
|
</td> |
|
<td> |
|
una clave (cadena) |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un valor |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map('1','uno','2', 'dos') |
|
</code> |
|
→ |
|
<code> |
|
{ '1': 'uno', '2': 'dos' } |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_akeys"><a href="#maps-map_akeys-idx"> |
|
función map_akeys |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve todas las claves de un mapa como una matriz. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_akeys |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
un mapa |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_akeys(map('1','uno','2','dos')) |
|
</code> |
|
→ |
|
<code> |
|
[ '1', '2' ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_avals"><a href="#maps-map_avals-idx"> |
|
función map_avals |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve todos los valores de un mapa como una matriz. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_avals |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
un mapa |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_avals(map('1','uno','2','dos')) |
|
</code> |
|
→ |
|
<code> |
|
[ 'uno', 'dos' ] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_concat"><a href="#maps-map_concat-idx"> |
|
función map_concat |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un mapa que contiene todas las entradas de los mapas dados. Si dos mapas contienen la misma clave, se toma el valor del segundo mapa. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_concat |
|
</span> |
|
( |
|
<span class="argument"> |
|
map1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
map2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
un mapa |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_concat(map('1','uno', '2','sobreescrito'),map('2','dos', '3','tres')) |
|
</code> |
|
→ |
|
<code> |
|
{ '1': 'uno, '2': 'dos', '3': 'tres' } |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_delete"><a href="#maps-map_delete-idx"> |
|
función map_delete |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un mapa con las claves dadas y sus valores correspondientes borrados. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_delete |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
, |
|
<span class="argument"> |
|
key |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
un mapa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
key |
|
</td> |
|
<td> |
|
la clave a borrar |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_delete(map('1','uno','2','dos'),'2') |
|
</code> |
|
→ |
|
<code> |
|
{ '1': 'uno' } |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_exist"><a href="#maps-map_exist-idx"> |
|
función map_exist |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve verdadero si la clave dada existe en el mapa. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_exist |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
, |
|
<span class="argument"> |
|
key |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
un mapa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
key |
|
</td> |
|
<td> |
|
la clave a buscar |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_exist(map('1','uno','2','dos'),'3') |
|
</code> |
|
→ |
|
<code> |
|
falso |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_get"><a href="#maps-map_get-idx"> |
|
función map_get |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor de un mapa, dada su clave. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_get |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
, |
|
<span class="argument"> |
|
key |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
un mapa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
key |
|
</td> |
|
<td> |
|
la clave a buscar |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_get(map('1','uno','2','dos'),'2') |
|
</code> |
|
→ |
|
<code> |
|
'dos' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_insert"><a href="#maps-map_insert-idx"> |
|
función map_insert |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve un mapa con una clave/valor añadidos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_insert |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
, |
|
<span class="argument"> |
|
key |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
un mapa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
key |
|
</td> |
|
<td> |
|
la clave a añadir |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
el valor a añadir |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_insert(map('1','uno'),'3','tres') |
|
</code> |
|
→ |
|
<code> |
|
{ '1': 'uno', '3': 'tres' } |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_to_hstore"><a href="#maps-map_to_hstore-idx"> |
|
función map_to_hstore |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Merge map elements into a hstore-formatted string. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_to_hstore |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
el mapa de entrada |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_to_hstore(map('qgis','rocks')) |
|
</code> |
|
→ |
|
<code> |
|
"qgis"=>"rocks"} |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-map_to_json"><a href="#maps-map_to_json-idx"> |
|
función map_to_json |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Merge map elements into a json-formatted string. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
map_to_json |
|
</span> |
|
( |
|
<span class="argument"> |
|
map |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
map |
|
</td> |
|
<td> |
|
el mapa de entrada |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
map_to_json(map('qgis','rocks')) |
|
</code> |
|
→ |
|
<code> |
|
{"qgis":"rocks"} |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="maps-to_json"><a href="#maps-to_json-idx"> |
|
función to_json |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Crear una cadena en formato JSON a partir de un mapa, arreglo u otro valor. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
to_json |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
El valor de entrada |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
to_json(map('qgis','rocks')) |
|
</code> |
|
→ |
|
<code> |
|
{"qgis":"rocks"} |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
to_json(array(1,2,3)) |
|
</code> |
|
→ |
|
<code> |
|
[1,2,3] |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="math" class="group"><h2><a href="#math-idx">grupo matemáticas</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones matemáticas, por ejemplo raíz cuadrada, seno y coseno</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-abs"><a href="#math-abs-idx"> |
|
función abs |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor absoluto de un número. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
abs |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un número |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
abs(-2) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-acos"><a href="#math-acos-idx"> |
|
función acos |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el arco coseno de un valor en radianes. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
acos |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
coseno de un ángulo en radianes |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
acos(0.5) |
|
</code> |
|
→ |
|
<code> |
|
1.0471975511966 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-asin"><a href="#math-asin-idx"> |
|
función asin |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el arcoseno de un valor en radianes. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
asin |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
seno de un ángulo en radianes |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
arcsen(1.0) |
|
</code> |
|
→ |
|
<code> |
|
1.5707963267949 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-atan"><a href="#math-atan-idx"> |
|
función atan |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la arcotangente de un valor en radianes. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
atan |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
tangente de un ángulo en radianes |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
arctan(0.5) |
|
</code> |
|
→ |
|
<code> |
|
0.463647609000806 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-atan2"><a href="#math-atan2-idx"> |
|
función atan2 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la arcotangente de dy/dx usandi los signos de los dos argumentos para determinar el cuadrante del resultado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
atan2 |
|
</span> |
|
( |
|
<span class="argument"> |
|
dy |
|
</span> |
|
, |
|
<span class="argument"> |
|
dx |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
dy |
|
</td> |
|
<td> |
|
diferencia de la coordenada Y |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
dx |
|
</td> |
|
<td> |
|
diferencia de la coordenada Y |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
arctan2(1.0, 1.732) |
|
</code> |
|
→ |
|
<code> |
|
0.523611477769969 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-azimuth"><a href="#math-azimuth-idx"> |
|
función azimuth |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el azimut basado en el Norte como el ángulo en radianes medido en sentido horario desde la vertical en el punto_A al Punto_b. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
azimuth |
|
</span> |
|
( |
|
<span class="argument"> |
|
point_a |
|
</span> |
|
, |
|
<span class="argument"> |
|
point_b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point_a |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point_b |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
degrees( azimuth( make_point(25, 45), make_point(75, 100) ) ) |
|
</code> |
|
→ |
|
<code> |
|
42.273689 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
degrees( azimuth( make_point(75, 100), make_point(25,45) ) ) |
|
</code> |
|
→ |
|
<code> |
|
222.273689 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-ceil"><a href="#math-ceil-idx"> |
|
función ceil |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Redondea un número por arriba. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
ceil |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un número |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
ceil(4.9) |
|
</code> |
|
→ |
|
<code> |
|
5 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
ceil(-4.9) |
|
</code> |
|
→ |
|
<code> |
|
-4 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-clamp"><a href="#math-clamp-idx"> |
|
función clamp |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Restringe un valor de entrada a un rango especificado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
clamp |
|
</span> |
|
( |
|
<span class="argument"> |
|
minimum |
|
</span> |
|
, |
|
<span class="argument"> |
|
input |
|
</span> |
|
, |
|
<span class="argument"> |
|
maximum |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
minimum |
|
</td> |
|
<td> |
|
el valor más pequeño que puede tomar |
|
<i> |
|
entrada |
|
</i> |
|
. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
input |
|
</td> |
|
<td> |
|
un valor que se puede restringir al intervalo especificado por |
|
<i> |
|
mínimo |
|
</i> |
|
y |
|
<i> |
|
máximo |
|
</i> |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
maximum |
|
</td> |
|
<td> |
|
el valor más grande que puede tomar |
|
<i> |
|
entrada |
|
</i> |
|
. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
clamp(1,5,10) |
|
</code> |
|
→ |
|
<code> |
|
5 |
|
</code> |
|
( |
|
<i> |
|
entrada |
|
</i> |
|
está entre 1 y 10 así que se devuelve sin cambio) |
|
</li> |
|
<li> |
|
<code> |
|
clamp(1,0,10) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
( |
|
<i> |
|
entrada |
|
</i> |
|
es menor que el valor mínimo de 1, así que la función devuelve 1) |
|
</li> |
|
<li> |
|
<code> |
|
clamp(1,11,10) |
|
</code> |
|
→ |
|
<code> |
|
10 |
|
</code> |
|
( |
|
<i> |
|
entrada |
|
</i> |
|
es mayor que el valor máximo de 10, así que la función devuelve 10) |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-cos"><a href="#math-cos-idx"> |
|
función cos |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el coseno de un ángulo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
cos |
|
</span> |
|
( |
|
<span class="argument"> |
|
angle |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
angle |
|
</td> |
|
<td> |
|
ángulo en radianes |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
cos(1.571) |
|
</code> |
|
→ |
|
<code> |
|
0.000796326710733263 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-degrees"><a href="#math-degrees-idx"> |
|
función degrees |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte de radianes a grados. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
degrees |
|
</span> |
|
( |
|
<span class="argument"> |
|
radians |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
radians |
|
</td> |
|
<td> |
|
valor numérico |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
degrees(3.14159) |
|
</code> |
|
→ |
|
<code> |
|
180 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
grados(1) |
|
</code> |
|
→ |
|
<code> |
|
57.2958 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-exp"><a href="#math-exp-idx"> |
|
función exp |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la exponencial de un valor. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
exp |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
número del que devolver la exponencial |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
exp(1.0) |
|
</code> |
|
→ |
|
<code> |
|
2.71828182845905 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-floor"><a href="#math-floor-idx"> |
|
función floor |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Redondea un número por abajo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
floor |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un número |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
floor(4.9) |
|
</code> |
|
→ |
|
<code> |
|
4 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
floor(-4.9) |
|
</code> |
|
→ |
|
<code> |
|
-5 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-inclination"><a href="#math-inclination-idx"> |
|
función inclination |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la inclinación medida desde el cénit (0) al nadir (180) en el punto A al punto B. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
inclination |
|
</span> |
|
( |
|
<span class="argument"> |
|
point_a |
|
</span> |
|
, |
|
<span class="argument"> |
|
point_b |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
point_a |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point_b |
|
</td> |
|
<td> |
|
geometría de punto |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 5, 10, 5 ) ) |
|
</code> |
|
→ |
|
<code> |
|
0.0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 5, 10, 0 ) ) |
|
</code> |
|
→ |
|
<code> |
|
90.0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 50, 100, 0 ) ) |
|
</code> |
|
→ |
|
<code> |
|
90.0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
inclination( make_point( 5, 10, 0 ), make_point( 5, 10, -5 ) ) |
|
</code> |
|
→ |
|
<code> |
|
180.0 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-ln"><a href="#math-ln-idx"> |
|
función ln |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el logaritmo neperiano de un valor. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
ln |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
valor numérico |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
ln(1) |
|
</code> |
|
→ |
|
<code> |
|
0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
ln(2.7182818284590452354) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-log"><a href="#math-log-idx"> |
|
función log |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el logaritmo del valor y la base pasados. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
log |
|
</span> |
|
( |
|
<span class="argument"> |
|
base |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
base |
|
</td> |
|
<td> |
|
cualquier número positivo |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
cualquier número positivo |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
log(2, 32) |
|
</code> |
|
→ |
|
<code> |
|
5 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
log(0.5, 32) |
|
</code> |
|
→ |
|
<code> |
|
-5 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-log10"><a href="#math-log10-idx"> |
|
función log10 |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el logaritmo en base 10 de la expresión pasada. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
log10 |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
cualquier número positivo |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
log10(1) |
|
</code> |
|
→ |
|
<code> |
|
0 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
log10(100) |
|
</code> |
|
→ |
|
<code> |
|
2 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-max"><a href="#math-max-idx"> |
|
función max |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor más grande de un conjunto de valores. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
max |
|
</span> |
|
( |
|
<span class="argument"> |
|
value1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
value2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un número |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
max(2,10.2,5.5) |
|
</code> |
|
→ |
|
<code> |
|
10.2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
max(20.5,NULL,6.2) |
|
</code> |
|
→ |
|
<code> |
|
20.5 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-min"><a href="#math-min-idx"> |
|
función min |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor más pequeño de un conjunto de valores. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
min |
|
</span> |
|
( |
|
<span class="argument"> |
|
value1 |
|
</span> |
|
, |
|
<span class="argument"> |
|
value2 |
|
</span> |
|
…) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un número |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
min(20.5,10,6.2) |
|
</code> |
|
→ |
|
<code> |
|
6.2 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
min(2,-10.3,NULL) |
|
</code> |
|
→ |
|
<code> |
|
-10.3 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-pi"><a href="#math-pi-idx"> |
|
función pi |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor de Pi para cálculos. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
pi |
|
</span> |
|
() |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
pi() |
|
</code> |
|
→ |
|
<code> |
|
3.14159265358979 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-radians"><a href="#math-radians-idx"> |
|
función radians |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Convierte de grados a radianes. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
radians |
|
</span> |
|
( |
|
<span class="argument"> |
|
degrees |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
degrees |
|
</td> |
|
<td> |
|
valor numérico |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
radianes(180) |
|
</code> |
|
→ |
|
<code> |
|
3.14159 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
radianes(57.2958) |
|
</code> |
|
→ |
|
<code> |
|
1 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-rand"><a href="#math-rand-idx"> |
|
función rand |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a random integer within the range specified by the minimum and maximum argument (inclusive). If a seed is provided, the returned will always be the same, depending on the seed. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
rand |
|
</span> |
|
( |
|
<span class="argument"> |
|
min |
|
</span> |
|
, |
|
<span class="argument"> |
|
max |
|
</span> |
|
[, |
|
<span class="argument"> |
|
seed=null |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
min |
|
</td> |
|
<td> |
|
un entero que representa el menor número aleatorio posible deseado |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
max |
|
</td> |
|
<td> |
|
un entero que representa el mayor número aleatorio posible deseado |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
seed |
|
</td> |
|
<td> |
|
any value to use as seed |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
rand(1, 10) |
|
</code> |
|
→ |
|
<code> |
|
8 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-randf"><a href="#math-randf-idx"> |
|
función randf |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a random float within the range specified by the minimum and maximum argument (inclusive). If a seed is provided, the returned will always be the same, depending on the seed. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
randf |
|
</span> |
|
([ |
|
<span class="argument"> |
|
min=0.0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
max=1.0 |
|
</span> |
|
][, |
|
<span class="argument"> |
|
seed=null |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
min |
|
</td> |
|
<td> |
|
un número de coma flotante que representa el menor número aleatorio posible deseado |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
max |
|
</td> |
|
<td> |
|
un número de coma flotante que representa el mayor número aleatorio posible deseado |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
seed |
|
</td> |
|
<td> |
|
any value to use as seed |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
randf(1, 10) |
|
</code> |
|
→ |
|
<code> |
|
4.59258286403147 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-round"><a href="#math-round-idx"> |
|
función round |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Redondea un número al número de posiciones decimales. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
round |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
[, |
|
<span class="argument"> |
|
places=0 |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
número decimal a redondear |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
places |
|
</td> |
|
<td> |
|
Entero opcional que representa el número de posiciones decimales al que redondear. Puede ser negativo. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
round(1234.567, 2) |
|
</code> |
|
→ |
|
<code> |
|
1234.57 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
round(1234.567) |
|
</code> |
|
→ |
|
<code> |
|
1235 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-scale_exp"><a href="#math-scale_exp-idx"> |
|
función scale_exp |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Transforma un valor dado de un dominio de entrada a un rango de salida usando una curva exponencial. Esta función se puede usar para facilitar valores dentro o fuera del rango de salida especificado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
scale_exp |
|
</span> |
|
( |
|
<span class="argument"> |
|
val |
|
</span> |
|
, |
|
<span class="argument"> |
|
domain_min |
|
</span> |
|
, |
|
<span class="argument"> |
|
domain_max |
|
</span> |
|
, |
|
<span class="argument"> |
|
range_min |
|
</span> |
|
, |
|
<span class="argument"> |
|
range_max |
|
</span> |
|
, |
|
<span class="argument"> |
|
exponent |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
val |
|
</td> |
|
<td> |
|
Un valor del dominio de entrada. La función devolverá un valor escalado correspondiente en el rango de salida. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
domain_min |
|
</td> |
|
<td> |
|
Especifica el valor mínimo del dominio de entrada, el valor más pequeño que debería tomar el valor de entrada. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
domain_max |
|
</td> |
|
<td> |
|
Especifica el valor máximo del dominio de entrada, el valor más grande que debería tomar el valor de entrada. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
range_min |
|
</td> |
|
<td> |
|
Especifica el valor mínimo del dominio de salida, el valor más pequeño que debería producir la función. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
range_max |
|
</td> |
|
<td> |
|
Especifica el valor máximo del dominio de salida, el valor más grande que debería producir la función. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
exponent |
|
</td> |
|
<td> |
|
Un valor positivo (mayor que 0) que dicta la forma en la que los valores de entrada son trasladados al rango de salida. Exponentes grandes harán que los valores de salida "converjan", comenzando lentamente antes de acelerar a medida que los valores de entrada se acercan al máximo del dominio. Exponentes más pequeños (menores que 1) harán que los valores de salida "diverjan", de forma que el traslado comienza rápidamente pero se ralentiza a medida que se aproxima al máximo del dominio. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
scale_exp(5,0,10,0,100,2) |
|
</code> |
|
→ |
|
<code> |
|
25 |
|
</code> |
|
("convergiendo", usando un exponente de 2) |
|
</li> |
|
<li> |
|
<code> |
|
scale_exp(3,0,10,0,100,0.5) |
|
</code> |
|
→ |
|
<code> |
|
54.772 |
|
</code> |
|
("divergiendo", usando un exponente de 0,5) |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-scale_linear"><a href="#math-scale_linear-idx"> |
|
función scale_linear |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Transforma un valor dado de un dominio de entrada a un rango de salida usando interpolación lineal. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
scale_linear |
|
</span> |
|
( |
|
<span class="argument"> |
|
val |
|
</span> |
|
, |
|
<span class="argument"> |
|
domain_min |
|
</span> |
|
, |
|
<span class="argument"> |
|
domain_max |
|
</span> |
|
, |
|
<span class="argument"> |
|
range_min |
|
</span> |
|
, |
|
<span class="argument"> |
|
range_max |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
val |
|
</td> |
|
<td> |
|
Un valor del dominio de entrada. La función devolverá un valor escalado correspondiente en el rango de salida. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
domain_min |
|
</td> |
|
<td> |
|
Especifica el valor mínimo del dominio de entrada, el valor más pequeño que debería tomar el valor de entrada. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
domain_max |
|
</td> |
|
<td> |
|
Especifica el valor máximo del dominio de entrada, el valor más grande que debería tomar el valor de entrada. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
range_min |
|
</td> |
|
<td> |
|
Especifica el valor mínimo del dominio de salida, el valor más pequeño que debería producir la función. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
range_max |
|
</td> |
|
<td> |
|
Especifica el valor máximo del dominio de salida, el valor más grande que debería producir la función. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
scale_linear(5,0,10,0,100) |
|
</code> |
|
→ |
|
<code> |
|
50 |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
scale_linear(0.2,0,1,0,360) |
|
</code> |
|
→ |
|
<code> |
|
72 |
|
</code> |
|
(escalando un valor entre 0 y 1 a un ángulo entre 0 y 360) |
|
</li> |
|
<li> |
|
<code> |
|
scale_linear(1500,1000,10000,9,20) |
|
</code> |
|
→ |
|
<code> |
|
9.6111111 |
|
</code> |
|
(escalando una poblacion que varía entre 1000 y 10000 a un tamaño de letra entre 9 y 20) |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-sin"><a href="#math-sin-idx"> |
|
función sin |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el seno de un ángulo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
sin |
|
</span> |
|
( |
|
<span class="argument"> |
|
angle |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
angle |
|
</td> |
|
<td> |
|
ángulo en radianes |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
sin(1.571) |
|
</code> |
|
→ |
|
<code> |
|
0.999999682931835 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-sqrt"><a href="#math-sqrt-idx"> |
|
función sqrt |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la raíz cuadrada de un valor. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
sqrt |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
un número |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
sqrt(9) |
|
</code> |
|
→ |
|
<code> |
|
3 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="math-tan"><a href="#math-tan-idx"> |
|
función tan |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve la tangente de un ángulo. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
tan |
|
</span> |
|
( |
|
<span class="argument"> |
|
angle |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
angle |
|
</td> |
|
<td> |
|
ángulo en radianes |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
tan(1.0) |
|
</code> |
|
→ |
|
<code> |
|
1.5574077246549 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="processing" class="group">falta la ayuda de la función para Processing</div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="processing-parameter"><a href="#processing-parameter-idx"> |
|
función parameter |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor del parámetro de entrada de un algoritmo de procesos |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
parameter |
|
</span> |
|
( |
|
<span class="argument"> |
|
name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
name |
|
</td> |
|
<td> |
|
nombre del parámetro de entrada correspondiente |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
parameter('BUFFER_SIZE') |
|
</code> |
|
→ |
|
<code> |
|
5.6 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="python" class="group">falta la ayuda de la función para Python</div> |
|
<div class="function"><html> |
|
<body> |
|
<p> |
|
falta la ayuda de la función para $mask_geometry |
|
</p> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<p> |
|
falta la ayuda de la función para in_mask |
|
</p> |
|
</body> |
|
</html></div> |
|
<div id="rasters" class="group"><h2><a href="#rasters-idx">grupo rásters</a></h2> |
|
<div class="description"><p>Contains functions which calculate raster statistics and values.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="rasters-raster_statistic"><a href="#rasters-raster_statistic-idx"> |
|
función raster_statistic |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve estadísticas de una capa ráster. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
raster_statistic |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
, |
|
<span class="argument"> |
|
band |
|
</span> |
|
, |
|
<span class="argument"> |
|
property |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
una cadena que representa bien el nombre de una capa ráster o el ID de la capa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
band |
|
</td> |
|
<td> |
|
entero que representa el número de banda de la capa ráster, comenzando por 1 |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
property |
|
</td> |
|
<td> |
|
una cadena que corresponde a la propiedad a devolver. Las opciones válidas son: |
|
<br/> |
|
<ul> |
|
<li> |
|
min: valor mínimo |
|
</li> |
|
<li> |
|
max: valor máximo |
|
</li> |
|
<li> |
|
avg: valor medio |
|
</li> |
|
<li> |
|
stdev: desviación estándar de los valores |
|
</li> |
|
<li> |
|
range: intervalo de valores (max - min) |
|
</li> |
|
<li> |
|
sum: suma de todos los valores del ráster |
|
</li> |
|
</ul> |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
raster_statistic('lc',1,'avg') |
|
</code> |
|
→ |
|
<code> |
|
Valor promedio de la banda 1 de la capa ráster 'lc' |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
raster_statistic('ac2010',3,'min') |
|
</code> |
|
→ |
|
<code> |
|
Valor mínimo de la banda 3 de la capa ráster 'ac2010' |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="rasters-raster_value"><a href="#rasters-raster_value-idx"> |
|
función raster_value |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el valor ráster encontrado en el punto suministrado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
raster_value |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
, |
|
<span class="argument"> |
|
band |
|
</span> |
|
, |
|
<span class="argument"> |
|
point |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
el nombre o id de una capa ráster |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
band |
|
</td> |
|
<td> |
|
the band number to sample the value from. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
point |
|
</td> |
|
<td> |
|
point geometry (for multipart geometries having more than one part, a null value will be returned) |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
raster_value('dem', 1, make_point(1,1)) |
|
</code> |
|
→ |
|
<code> |
|
25 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div id="record-and-attributes" class="group"><h2><a href="#record-and-attributes-idx">grupo registros y atributos</a></h2> |
|
<div class="description"><p>Este grupo contiene funciones que operan sobre identificadores de registros.</p></div></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-dollar-currentfeature"><a href="#record-and-attributes-dollar-currentfeature-idx"> |
|
función $currentfeature |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el objeto espacial que está siendo evaluado. Se puede usar con la función 'attribute' para evaluar los valores de atributo del objeto actual. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$currentfeature |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
attribute( $currentfeature, 'nombre' ) |
|
</code> |
|
→ |
|
<code> |
|
valor guardado en el atributo 'nombre' del objeto actual |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-dollar-id"><a href="#record-and-attributes-dollar-id-idx"> |
|
función $id |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el ID del objeto de la fila actual. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
$id |
|
</span> |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
$id |
|
</code> |
|
→ |
|
<code> |
|
42 |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-attribute"><a href="#record-and-attributes-attribute-idx"> |
|
función attribute |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns an attribute from a feature. |
|
</p> |
|
</div> |
|
<h3 id="record-and-attributes-attribute"><a href="#record-and-attributes-attribute-idx"> |
|
Variante 1 |
|
</a></h3> |
|
<div class="description"> |
|
Devuelve el valor de un atributo del objeto actual. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
attribute |
|
</span> |
|
( |
|
<span class="argument"> |
|
attribute_name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
attribute_name |
|
</td> |
|
<td> |
|
nombre del atributo a devolver |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
attribute( 'name' ) |
|
</code> |
|
→ |
|
<code> |
|
valor guardado en el atributo 'nombre' del objeto actual |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="record-and-attributes-attribute"><a href="#record-and-attributes-attribute-idx"> |
|
Variante 2 |
|
</a></h3> |
|
<div class="description"> |
|
Allows the target feature and attribute name to be specified. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
attribute |
|
</span> |
|
( |
|
<span class="argument"> |
|
feature |
|
</span> |
|
, |
|
<span class="argument"> |
|
attribute_name |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
feature |
|
</td> |
|
<td> |
|
un objeto espacial |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
attribute_name |
|
</td> |
|
<td> |
|
nombre del atributo a devolver |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
attribute( @atlas_feature, 'nombre' ) |
|
</code> |
|
→ |
|
<code> |
|
valor guardado en el atributo 'nombre' del objeto de atlas actual |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-attributes"><a href="#record-and-attributes-attributes-idx"> |
|
función attributes |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns a map containing all attributes from a feature, with field names as map keys. |
|
</p> |
|
</div> |
|
<h3 id="record-and-attributes-attributes"><a href="#record-and-attributes-attributes-idx"> |
|
Variante 1 |
|
</a></h3> |
|
<div class="description"> |
|
Returns a map of all attributes from the current feature. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
attributes |
|
</span> |
|
() |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
attributes()['name'] |
|
</code> |
|
→ |
|
<code> |
|
valor guardado en el atributo 'nombre' del objeto actual |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="record-and-attributes-attributes"><a href="#record-and-attributes-attributes-idx"> |
|
Variante 2 |
|
</a></h3> |
|
<div class="description"> |
|
Allows the target feature to be specified. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
attributes |
|
</span> |
|
( |
|
<span class="argument"> |
|
feature |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
feature |
|
</td> |
|
<td> |
|
un objeto espacial |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
attributes( @atlas_feature )['name'] |
|
</code> |
|
→ |
|
<code> |
|
valor guardado en el atributo 'nombre' del objeto de atlas actual |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-display_expression"><a href="#record-and-attributes-display_expression-idx"> |
|
función display_expression |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the display expression for a given feature in a layer. If called with no parameters, it evaluates the current feature. The expression is evaluated by default. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
display_expression |
|
</span> |
|
([ |
|
<span class="argument"> |
|
feature=current feature |
|
</span> |
|
][, |
|
<span class="argument"> |
|
layer=current layer |
|
</span> |
|
][, |
|
<span class="argument"> |
|
evaluate=true |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
feature |
|
</td> |
|
<td> |
|
The feature which should be evaluated. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
The layer (or its id or name). |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
evaluate |
|
</td> |
|
<td> |
|
If the expression must be evaluated. If false, the expression will be returned as a string literal only (which could potentially be later evaluated using the 'eval' function). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
display_expression() |
|
</code> |
|
→ |
|
<code> |
|
The display expression of the current feature. |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
display_expression(get_feature_by_id('streets', 1), 'streets') |
|
</code> |
|
→ |
|
<code> |
|
The display expression of the feature with the ID 1 on the layer 'streets'. |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
display_expression('a_layer_id', $currentfeature, 'False') |
|
</code> |
|
→ |
|
<code> |
|
The display expression of the given feature not evaluated. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-get_feature"><a href="#record-and-attributes-get_feature-idx"> |
|
función get_feature |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el primer objeto de una capa que coincide con un valor de atributo dado. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
get_feature |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
, |
|
<span class="argument"> |
|
attribute |
|
</span> |
|
, |
|
<span class="argument"> |
|
value |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
nombre o ID de capa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
attribute |
|
</td> |
|
<td> |
|
nombre del atributo |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
valor de atributo con el que coincidir |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
get_feature('calles','nombre','calle principal') |
|
</code> |
|
→ |
|
<code> |
|
primer objeto encontrado en la capa "calles" con el valor "calle principal" en el campo "nombre" |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-get_feature_by_id"><a href="#record-and-attributes-get_feature_by_id-idx"> |
|
función get_feature_by_id |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el objeto de una capa con una ID. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
get_feature_by_id |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
, |
|
<span class="argument"> |
|
feature_id |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
capa, nombre de capa o ID de capa |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
feature_id |
|
</td> |
|
<td> |
|
la ID del objeto que se debe devolver |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
get_feature('calles', 1) |
|
</code> |
|
→ |
|
<code> |
|
el objeto con ID 1 de la capa "calles" |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-is_selected"><a href="#record-and-attributes-is_selected-idx"> |
|
función is_selected |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns True if a feature is selected. Can be used with zero, one or two arguments, see below for details. |
|
</p> |
|
</div> |
|
<h3 id="record-and-attributes-is_selected"><a href="#record-and-attributes-is_selected-idx"> |
|
No parameters |
|
</a></h3> |
|
<div class="description"> |
|
If called with no parameters, the function will return true if the current feature in the current layer is selected. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_selected |
|
</span> |
|
() |
|
</code> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
está_seleccionado() |
|
</code> |
|
→ |
|
<code> |
|
True if the current feature in the current layer is selected. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="record-and-attributes-is_selected"><a href="#record-and-attributes-is_selected-idx"> |
|
One 'feature' parameter |
|
</a></h3> |
|
<div class="description"> |
|
If called with a 'feature' parameter only, the function returns true if the specified feature from the current layer is selected. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_selected |
|
</span> |
|
( |
|
<span class="argument"> |
|
feature |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
feature |
|
</td> |
|
<td> |
|
El objeto que se debería comprobar si está o no seleccionado. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_selected(@atlas_feature) |
|
</code> |
|
→ |
|
<code> |
|
True if the current atlas feature is selected. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
<h3 id="record-and-attributes-is_selected"><a href="#record-and-attributes-is_selected-idx"> |
|
Two parameters |
|
</a></h3> |
|
<div class="description"> |
|
If the function is called with both a layer and a feature, it will return true if the specified feature from the specified layer is selected. |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
is_selected |
|
</span> |
|
( |
|
<span class="argument"> |
|
layer |
|
</span> |
|
, |
|
<span class="argument"> |
|
feature |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
The layer (or its ID or name) on which the selection will be checked. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
feature |
|
</td> |
|
<td> |
|
El objeto que se debería comprobar si está o no seleccionado. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
is_selected( 'streets', get_feature('streets', 'name', "street_name")) |
|
</code> |
|
→ |
|
<code> |
|
True if the current building's street is selected (assuming the building layer has a field named 'street_name' and the 'streets' layer has a field called 'name'). |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-maptip"><a href="#record-and-attributes-maptip-idx"> |
|
función maptip |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the maptip for a given feature in a layer. If called with no parameters, it evaluates the current feature. The maptip is evaluated by default. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
maptip |
|
</span> |
|
([ |
|
<span class="argument"> |
|
feature=current feature |
|
</span> |
|
][, |
|
<span class="argument"> |
|
layer=current layer |
|
</span> |
|
][, |
|
<span class="argument"> |
|
evaluate=true |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
feature |
|
</td> |
|
<td> |
|
The feature which should be evaluated. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
The layer (or its id or name). |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
evaluate |
|
</td> |
|
<td> |
|
If the expression must be evaluated. If false, the expression will be returned as a string literal only (which could potentially be later evaluated using the 'eval_template' function). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
maptip() |
|
</code> |
|
→ |
|
<code> |
|
The maptip of the current feature. |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
maptip(get_feature('streets', 1), 'streets') |
|
</code> |
|
→ |
|
<code> |
|
The maptip of the feature with the ID 1 on the layer 'streets'. |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
maptip('a_layer_id', $currentfeature, 'False') |
|
</code> |
|
→ |
|
<code> |
|
The maptip of the given feature not evaluated. |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-num_selected"><a href="#record-and-attributes-num_selected-idx"> |
|
función num_selected |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Devuelve el número de objetos seleccionados de una capa dada. Por omisión se aplica a la capa en la que se evalúa la expresión. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
num_selected |
|
</span> |
|
([ |
|
<span class="argument"> |
|
layer=current layer |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
layer |
|
</td> |
|
<td> |
|
La capa (o su ID o nombre) sobre la que se comprobará la selección. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
num_selected() |
|
</code> |
|
→ |
|
<code> |
|
El número de objetos seleccionados de la capa actual. |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
num_selected('calles') |
|
</code> |
|
→ |
|
<code> |
|
El ńumero de objetos seleccionados de la capa calles |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-represent_value"><a href="#record-and-attributes-represent_value-idx"> |
|
función represent_value |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Returns the configured representation value for a field value. It depends on the configured widget type. Often, this is useful for 'Value Map' widgets. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
represent_value |
|
</span> |
|
( |
|
<span class="argument"> |
|
value |
|
</span> |
|
, |
|
<span class="argument"> |
|
fieldName |
|
</span> |
|
) |
|
</code> |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
value |
|
</td> |
|
<td> |
|
El valor que se debe resolver. Probablemente un campo. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
fieldName |
|
</td> |
|
<td> |
|
El nombre de campo para el que se debe cargar la configuración del control. (Opcional). |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejemplos |
|
</h4> |
|
<div class="examples"> |
|
<ul> |
|
<li> |
|
<code> |
|
represent_value("field_with_value_map") |
|
</code> |
|
→ |
|
<code> |
|
Descripción para valor |
|
</code> |
|
</li> |
|
<li> |
|
<code> |
|
represent_value('static value', 'field_name') |
|
</code> |
|
→ |
|
<code> |
|
Descripción para valor estático |
|
</code> |
|
</li> |
|
</ul> |
|
</div> |
|
</div> |
|
</body> |
|
</html></div> |
|
<div class="function"><html> |
|
<body> |
|
<h3 id="record-and-attributes-sqlite_fetch_and_increment"><a href="#record-and-attributes-sqlite_fetch_and_increment-idx"> |
|
función sqlite_fetch_and_increment |
|
</a></h3> |
|
<div class="description"> |
|
<p> |
|
Manage autoincrementing values in sqlite databases. |
|
</p> |
|
<p> |
|
SQlite default values can only be applied on insert and not prefetched. |
|
</p> |
|
<p> |
|
This makes it impossible to acquire an incremented primary key via AUTO_INCREMENT before creating the row in the database. Sidenote: with postgres, this works via the option |
|
<i> |
|
evaluate default values |
|
</i> |
|
. |
|
</p> |
|
<p> |
|
When adding new features with relations, it is really nice to be able to already add children for a parent, while the parents form is still open and hence the parent feature uncommitted. |
|
</p> |
|
<p> |
|
To get around this limitation, this function can be used to manage sequence values in a separate table on sqlite based formats like gpkg. |
|
</p> |
|
<p> |
|
The sequence table will be filtered for a sequence id (filter_attribute and filter_value) and the current value of the id_field will be incremented by 1 and the incremented value returned. |
|
</p> |
|
<p> |
|
If additional columns require values to be specified, the default_value map can be used for this purpose. |
|
</p> |
|
<p> |
|
<b> |
|
Note |
|
</b> |
|
<br/> |
|
This function modifies the target sqlite table. It is intended for usage with default value configurations for attributes. |
|
</p> |
|
<p> |
|
When the database parameter is a layer and the layer is in transaction mode, the value will only be retrieved once during the lifetime of a transaction and cached and incremented. This makes it unsafe to work on the same database from several processes in parallel. |
|
</p> |
|
</div> |
|
<h4> |
|
Sintaxis |
|
</h4> |
|
<div class="syntax"> |
|
<code> |
|
<span class="functionname"> |
|
sqlite_fetch_and_increment |
|
</span> |
|
( |
|
<span class="argument"> |
|
database |
|
</span> |
|
, |
|
<span class="argument"> |
|
table |
|
</span> |
|
, |
|
<span class="argument"> |
|
id_field |
|
</span> |
|
, |
|
<span class="argument"> |
|
filter_attribute |
|
</span> |
|
, |
|
<span class="argument"> |
|
filter_value |
|
</span> |
|
[, |
|
<span class="argument"> |
|
default_values |
|
</span> |
|
]) |
|
</code> |
|
<br/> |
|
<br/> |
|
[ ] marque componentes opcionales |
|
<h4> |
|
Argumentos |
|
</h4> |
|
<div class="arguments"> |
|
<table> |
|
<tr> |
|
<td class="argument"> |
|
database |
|
</td> |
|
<td> |
|
Path to the sqlite file or geopackage layer |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
table |
|
</td> |
|
<td> |
|
Name of the table that manages the sequences |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
id_field |
|
</td> |
|
<td> |
|
Name of the field that contains the current value |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter_attribute |
|
</td> |
|
<td> |
|
Name the field that contains a unique identifier for this sequence. Must have a UNIQUE index. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
filter_value |
|
</td> |
|
<td> |
|
Name of the sequence to use. |
|
</td> |
|
</tr> |
|
<tr> |
|
<td class="argument"> |
|
default_values |
|
</td> |
|
<td> |
|
Map with default values for additional columns on the table. The values need to be fully quoted. Functions are allowed. |
|
</td> |
|
</tr> |
|
</table> |
|
</div> |
|
<h4> |
|
Ejem |