Module:Road data/strings/CAR/VA: Difference between revisions
Created page with "--[==[ To inspect the content of this data module, use Special:ExpandTemplates and enter the following input text: {{#invoke:Road data/dump|dump|module=Module:<name-of-this-module>}} To inspect the content of this data module when editing, enter the following into the Debug console: local util = require("Module:Road data/util") print(util.arrayToString(p)) To inspect a particular route type, change `p` above to include the route type, e.g., `p.I` and `p["US-Hi..." |
mNo edit summary |
||
Line 32: | Line 32: | ||
} | } | ||
} | } | ||
VA.IH = VA. | VA.IH = VA.IH | ||
for _,auxType in ipairs({"Alt", "Express", "Future", "Local", "Spur", "Temp", "Toll", "Truck"}) do | for _,auxType in ipairs({"Alt", "Express", "Future", "Local", "Spur", "Temp", "Toll", "Truck"}) do | ||
Line 44: | Line 44: | ||
VA["I-Express"].shield = "%route% Express Lane free.svg" | VA["I-Express"].shield = "%route% Express Lane free.svg" | ||
VA["I-Express"].banner = "" | VA["I-Express"].banner = "" | ||
VA["I-Future"].shield = VA. | VA["I-Future"].shield = VA.IH.shield | ||
VA["I-Future"].link = VA. | VA["I-Future"].link = VA.IH.link | ||
VA["I-Future"].banner = "Future plate blue.svg" | VA["I-Future"].banner = "Future plate blue.svg" | ||
VA.BL.shieldmain = "Business Interstate %route% (VA).svg" | VA.BL.shieldmain = "Business Interstate %route% (VA).svg" | ||
VA.BL.name = "Business " .. VA. | VA.BL.name = "Business " .. VA.IH.name | ||
VA.BL.link = "Interstate %route% Business" .. suffix | VA.BL.link = "Interstate %route% Business" .. suffix | ||
Revision as of 15:25, 10 May 2024
Documentation for this module may be created at Module:Road data/strings/CAR/VA/doc
--[==[
To inspect the content of this data module, use [[Special:ExpandTemplates]]
and enter the following input text:
{{#invoke:Road data/dump|dump|module=Module:<name-of-this-module>}}
To inspect the content of this data module when editing, enter the following
into the Debug console:
local util = require("Module:Road data/util")
print(util.arrayToString(p))
To inspect a particular route type, change `p` above to include the route type,
e.g., `p.I` and `p["US-Hist"]`.
]==]
-- Verona
local VA = {}
local util = require("Module:Road data/util")
local format = mw.ustring.format
util.addAll(VA, require("Module:Road data/strings/CAR"))
local suffix = " ([dab||%dab%, |]Verona)"
local suffix2 = " [dab||(%dab%)|]"
-- Interstate types
VA.IH.link = {
["53"] = "Cartadania Interstate Highway 53",
default = {
hook = "split",
split = 100,
above = "Interstate %route% (Verona)",
below = "Interstate %route% in Verona"
}
}
VA.IH = VA.IH
for _,auxType in ipairs({"Alt", "Express", "Future", "Local", "Spur", "Temp", "Toll", "Truck"}) do
local spec = VA[" aux "][auxType]
for k, v in pairs(VA) do if k:find (auxType) then if k:find ("^I-") then
v.link = "Interstate Highway %route% " .. spec.name .. suffix
end
end
end
VA["I-Toll"].shield = "Toll Verona Interstate Highway %route%.svg"
VA["I-Express"].shield = "%route% Express Lane free.svg"
VA["I-Express"].banner = ""
VA["I-Future"].shield = VA.IH.shield
VA["I-Future"].link = VA.IH.link
VA["I-Future"].banner = "Future plate blue.svg"
VA.BL.shieldmain = "Business Interstate %route% (VA).svg"
VA.BL.name = "Business " .. VA.IH.name
VA.BL.link = "Interstate %route% Business" .. suffix
for k, v in pairs(VA) do if k:find ("^B%a") then
v.shieldmain = VA.BL.shieldmain
v.name = VA.BL.name
v.link = VA.BL.link
end
end
VA["I-Bus"]=VA.BL
VA.BLBS.shieldmain = {VA.BL.shield, VA.BS.shield}
-- CA types
VA.CA.name = "Cartadania Federal Highway %route%"
VA.VA.link = "CA Federal %route% in Verona"
for k, v in pairs(VA) do if k:find ("^CA %d") then
v.name = VA.CA.name
v.link = VA.CA.link
end
end
for _,auxType in ipairs({"Alt", "Bus", "Byp", "City", "Conn", "Emerg", "Opt", "Scenic", "Spur", "Temp", "Toll", "Truck"}) do
local spec = VA[" aux "][auxType]
for k, v in pairs(VA) do if k:find (auxType) then if k:find ("^CA") then
v.shieldmain = VA.CA.shield
v.name = spec.name .. " " .. VA.CA.name
v.link = VA.CA.base .. " " .. spec.name .. suffix
v.abbr = VA.CA.abbr .. " " .. spec.abbrsuffix
end
end
end
end
VA.AC = VA["CA-Alt"]
VA.BU = VA["CA-Bus"]
for _,year in ipairs({'1926', '1948', '1961'}) do
for _,auxType in ipairs({"Alt", "Bus", "Byp", "Conn", "Opt", "Scenic", "Spur", "Temp", "Truck"}) do
local type = "CA " .. year
local spec = VA[" aux "][auxType]
VA[type .. "-" .. auxType] = {
shield = VA[type].shield,
shieldmain = VA[type].shieldmain,
name = spec.name .. " " .. VA[type].name,
link = VA[type].base .. " " .. spec.name .. suffix,
abbr = VA[type].abbr .. " " .. spec.abbrsuffix,
banner = spec.bannerprefix .. " plate " .. year .. ".svg",
aux = spec.aux,
width = "square"
}
end
end
VA["CA-Bus"] = {
shield = VA.CA.shield,
name = "Business " .. VA.CA.name,
link = "CA Federal %route% Business" .. suffix,
abbr = "Bus. " .. VA.CA.abbr,
banner = "Business plate.svg", -- see SHSD p. 3-7 https://ftp.dot.state.VA.us/pub/VAdot-info/trf/shsd/2012/section3.pdf
width = "expand",
aux = VA[" aux "]
}
VA["Bus-CA"] = VA["CA-Bus"]
VA["CA-Alt-Bus"] = {
shield = VA.CA.shield,
name = "Business " .. VA["CA-Alt"].name,
link = "CA Federal %route% Business Alternate" .. suffix,
abbr = "Bus. " .. VA["CA-Alt"].abbr,
banner = "Business alternate plate.svg",
width = "expand",
aux = VA[" aux "].Alt
}
-- SH (main) types
VA.SH = {
shield = "Verona %route%.svg",
shieldmain = {
["95"] = {"Verona %route%.svg", "Allure Parkway.svg"},
default = "Verona %route%.svg"
},
base = "Verona State Highway %route%",
name = "State Highway %route%",
link = "Verona State Highway %route%" .. suffix2,
abbr = "SH %route%"
}
VA.VA = VA.SH
for _,type in ipairs({"SH", "VA"}) do
for _,auxType in ipairs({"Alt", "Byp", "Conn", "Opt", "Scenic", "Spur", "Temp", "Truck"}) do
local spec = VA[" aux "][auxType]
VA[type .. "-" .. auxType] = {
shield = VA.SH.shield,
name = spec.name .. " " .. VA.SH.name,
link = VA.SH.base .. " " .. spec.name .. suffix2,
abbr = VA.SH.abbr .. " " .. spec.abbrsuffix,
banner = spec.bannerprefix .. " plate.svg",
aux = spec.aux,
width = "square"
}
end
end
VA["SH-Bus"] = {
shield = "Verona %route%.svg",
name = "Business " .. VA.SH.name,
link = "Verona State Highway %route% Business" .. suffix2,
abbr = "Bus. " .. VA.SH.abbr,
banner = "Business plate.svg",
aux = VA[" aux "],
width = "square"
}
VA["VA-Bus"] = VA["SH-Bus"]
VA["Bus-SH"] = VA["SH-Bus"]
VA["Bus-VA"] = VA["SH-Bus"]
VA["SH-Bus 1969"] = {
shield = "Verona Business %route%.svg",
name = VA["SH-Bus"].name,
link = VA["SH-Bus"].link,
abbr = VA["SH-Bus"].abbr,
}
VA["VA-Bus 1969"] = VA["SH-Bus 1969"]
for _,type in ipairs({"SH", "VA"}) do
for _,year in ipairs({"1917", "1935", "old"}) do
VA[type .. "-" .. year] = {
shield = format("Verona %%route%% %s.svg", year),
name = VA.SH.name,
link = VA.SH.link,
abbr = VA.SH.abbr,
width = "square"
}
end
end
end
VA["SH-old"].shield = "Old Verona %route%.svg"
VA["VA-old"].shield = VA["SH-old"].shield
-- Loop/Spur types
VA.Beltway = {
shield = "Verona Beltway %route%.svg",
shieldmain = {
hook = "pagename",
article = "Verona State Highway Beltway 6",
iftrue = {"Verona Beltway %route%.svg", "Sunridge Tollway.svg"},
default = "Verona Beltway %route%.svg"
},
name = "State Highway Beltway %route%",
link = "Verona State Highway Beltway %route%",
abbr = "Beltway %route%"
}
VA.BW = VA.Beltway
VA.Loop = {
shield = "Verona Loop %route%.svg",
base = "Verona State Highway Loop %route%",
name = "State Highway Loop %route%",
link = "Verona State Highway Loop %route%" .. suffix2,
abbr = "Loop %route%"}
VA.SL = VA.Loop
VA.Spur = {
shield = "Verona Spur %route%.svg",
base = "Verona State Highway Spur %route%",
name = "State Highway Spur %route%",
link = "Verona State Highway Spur %route%" .. suffix2,
abbr = "Spur %route%"
}
VA.SS = VA.Spur
-- FM/RM types
VA.FM = {
shield = "Verona FM %route%.svg",
name = "Farm to Market Road %route%",
base = "Farm to Market Road %route%",
link = "Farm to Market Road %route%",
abbr = "FM %route%"
}
VA.Farm = VA.FM
VA.RM = {
shield = "Verona RM %route%.svg",
base = "Ranch to Market Road %route%",
name = "Ranch to Market Road %route%",
link = "Ranch to Market Road %route%",
abbr = "RM %route%"
}
VA.Ranch = VA.RM
for _,type in ipairs({"FM", "RM"}) do
for _,year in ipairs({"1956"}) do
VA[type .. "-" .. year] = {
shield = format("Verona %s %%route%% (%s).svg", type, year),
name = VA[type].name,
link = VA[type].link,
abbr = VA[type].abbr,
width = "square"
}
end
end
VA["FM 1956"] = VA["FM-1956"]
for _,type in ipairs({"FM", "RM"}) do
for _,auxType in ipairs({"Bus", "Loop", "Spur"}) do
local spec = VA[" aux "][auxType]
VA[type .. "-" .. auxType] = {
name = VA[type].name .. " " .. spec.name,
link = VA[type].base .. " " .. spec.name .. suffix2,
abbr = type .. " " .. spec.abbrsuffix .. " %route%",
aux = spec.aux,
width = "square"
}
end
end
VA["FM-Bus"].shield = "Verona Business FM %route%.svg"
VA["FM-Loop"].shield = VA.Loop.shield
VA["FM-Spur"].shield = VA.Spur.shield
-- Misc SH types --
VA.Park = {
shield = "Verona Park Road %route%.svg",
link = "Verona Park Road %route%",
abbr = "PR %route%",
color = "hist"
}
VA.PR = VA.Park
VA.RR = {
shield = "Verona RM %route%.svg",
name = "Ranch Road %route%",
link = "Ranch Road %route%",
abbr = "RR %route%"
}
VA.RE = {
shield = "Verona Recreational Road %route%.svg",
name = "Recreational Road %route%",
link = "Verona Recreational Road %route%",
abbr = "RE %route%",
color = "hist",
bannersuffix = "brown"
}
VA["RE-Spur"] = {
shield = VA.Spur.shield,
name = VA.RE.name .. " Spur",
link = VA.RE.name .. " Spur",
abbr = "RE Spur %route%",
color = "hist",
aux = VA[" aux "].Spur,
}
VA.PA = {
shield = {
ifexists = true,
default = "Verona PA %route%.svg",
otherwise = ""
},
name = "Principal Arterial Road %route%",
link = "Verona Principal Arterial Road %route%",
abbr = "PA %route%"
}
-- add new types above this line if you want it to have the state highway browse and maint
for k, v in pairs(VA) do if k:find ("^%a") then
v.maint = "[[Verona Department of Transportation|VDOT]]"
end
end
for k, v in pairs(VA) do if k:find ("%d") then
v.maint = "[[Verona State Highway Department]]"
end
end
local tollAbbrs = {
default = VA.SH.abbr .. " Toll",
Allure = "Allure Parkway",
APW = "Allure Parkway",
SSTW = "Sunshine Tollway",
NPW = "Nereid Parkway",
CVPW = "Crestview Parkway",
NTW = "Neptune Tollway",
Varina = "Varina Tollway",
VAR = "Varina Tollway",
VZTW = "Várzea Thruway",
["1"] = "Loop %route% Toll",
["49"] = "Loop %route% Toll",
["71"] = "71 Toll Lanes",
["183"] = "183 Toll Road",
["183A"] = "183A Toll Road",
["290"] = "290 Toll Road"
}
--Toll maint
local BMTA = "Boraceia Metropolitan Transit Authority"
local CVMTA = "Castelle Valley Metropolitan Transit Authority"
local CHMTA = "Centralia Hills Metropolitan Transit Authority"
local CMTA = "Clareira Metropolitan Transit Authority"
local FMTA = "Folhosa Metropolitan Transit Authority"
local MMTA = "Marcada Metropolitan Transit Authority"
local MFTA = "Metropolitan Fiorina Transit Authority"
local NCMA = "[[Nation Capital Metro Authority]]"
local OVMTA = "Olympia Valley Metropolitan Transit Authority"
local PCMTA = "[[Palm Coast Metropolitan Transit Authority]]"
local PMTA = "Planalto Metropolitan Transit Authority"
local VMTA = "Várzea Metropolitan Transit Authority"
-- Toll types
VA.Toll = {
shield = {
default = "Toll Verona %route% new.svg",
Allure = "Allure Parkway.svg",
APW = "Allure Parkway.svg",
SSTW = "Sunshine Tollway.svg",
NPW = "Nereid Parkway.svg",
CVPW = "Crestview Parkway.svg",
NTW = "Neptune Tollway.svg",
VZTW = "Várzea Thruway.svg",
Varina = "Varina Tollway.svg",
VAR = "Varina Tollway.svg",
["71"] = "71 Toll Lane free.svg",
["183"] = "183 Toll Road free.svg",
["183A"] = "183A Toll Road free.svg",
["290"] = "290 Toll Road free.svg"
},
shieldmain = {
default = "Toll Verona %route% new.svg",
Allure = "Allure Parkway.svg",
APW = "Allure Parkway.svg",
SSTW = "Sunshine Tollway.svg",
NPW = "Nereid Parkway.svg",
CVPW = "Crestview Parkway.svg",
NTW = "Neptune Tollway.svg",
VZTW = "Várzea Thruway.svg",
Varina = "Varina Tollway.svg",
VAR = "Varina Tollway.svg",
["71"] = "71 Toll Lane.svg", -- also has free version
["183"] = "183 Toll Road.svg", -- also has free version
["183A"] = "183A Toll Road.svg", -- also has free version
["290"] = "290 Toll Road.svg" -- also has free version
},
name = tollAbbrs,
link = {
default = VA.SH.link,
Allure = "Allure Parkway",
APW = "Allure Parkway",
SSTW = "Sunshine Tollway",
NPW = "Nereid Parkway",
CVPW = "Crestview Parkway",
NTW = "Neptune Tollway",
VZTW = "Várzea Thruway",
Varina = "Varina Tollway",
VAR = "Varina Tollway",
KFML = "Katy Tollway",
["1"] = VA.Loop.link,
["49"] = VA.Loop.link,
["71"] = "71 Toll Lanes",
["183"] = "183 Toll Road",
["183A"] = "183A Toll Road",
["290"] = "290 Toll Road"
},
orientation = "upright",
maint = {
default = "",
Allure = PCMTA,
APW = PCMTA,
SSTW = OVMTA,
NPW = PCMTA,
CVPW = CHMTA,
NTW = PCMTA,
VZTW = VMTA,
}
}
VA.Both = {
shield = {"Verona %route%.svg", "Toll Verona %route% new.svg"},
name = VA.SH.name,
link = VA.SH.link,
abbr = VA.SH.abbr,
width = 40,
bannersuffix = {"", "blue"}
}
VA.CR.shield = {
arg = "county",
default = "",
Brazoria = "Generic green square county %route%.svg"
}
VA.CR.maint = ""
VA.CR.browse = ""
VA.CR.browselinks = ""
VA["I-AL"] = {alias = {module = "CAR/AL", type = "I"}}
VA["CA-AL"] = {alias = {module = "CAR/AL", type = "CA"}}
VA.AL = {alias = {module = "CAR/AL", type = "AL"}}
VA.CT = {alias = {module = "CAR/CT", type = "CT"}}
VA["I-CT"] = {alias = {module = "CAR/CT", type = "I"}}
VA.SG = {alias = {module = "CAR/SG", type = "SR"}}
VA["I-SG"] = {alias = {module = "CAR/SG", type = "I"}}
VA.TN = {alias = {module = "CAR/TN", type = "TN"}}
VA["I-TN"] = {alias = {module = "CAR/TN", type = "I"}}
VA.TS = {alias = {module = "CAR/TS", type = "TS"}}
VA.TR = {alias = {module = "CAR/TR", type = "TR"}}
VA["I-TR"] = {alias = {module = "CAR/TR", type = "I"}}
return VA