Module:Road data/strings/USA/NJ explained

--[==[ To inspect the content of this data module, use [[Special:ExpandTemplates]]and enter the following input text:

To inspect the content of this data module when editing, enter the followinginto 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"]`.]

]

-- New Jerseylocal NJ = require("Module:Road data/strings/USA")

local util = require("Module:Road data/util")local format = mw.ustring.format

local suffix = " ([dab||%dab%, |]New Jersey)"local suffix2 = " [dab||(%dab%)|]"local maint = "NJDOT"

NJ.I.link =

for k, v in pairs(NJ) do if k:find ("^I") then v.link = NJ.I.link endend

NJ["I-Alt"].banner = "Alt plate blue.svg"

NJ.US.shield = NJ.US.link = for _,auxType in ipairs do local spec = NJ[" aux "][auxType] for k, v in pairs(NJ) do if k:find (auxType) then if k:find ("^US") then v.shield = NJ.US.shield v.link = NJ.US.base .. " " .. spec.name .. suffix end end endend

for k, v in pairs(NJ) do if k:find ("^US %d") then v.link = NJ.US.link endend

for _,year in ipairs do for _,auxType in ipairs do local spec = NJ[" aux "][auxType] NJ["US " .. year .. "-" .. auxType] = endend NJ.SR = NJ.NJ = NJ.SRNJ.Route = NJ.SR

for _,type in ipairs do for _,auxType in ipairs do local spec = NJ[" aux "][auxType] NJ[type .. "-" .. auxType] = endend

NJ["SR 1956"] = NJ["NJ 1956"] = NJ["SR 1956"]

NJ["SR 1926"] = NJ["NJ 1926"] = NJ["SR 1926"]NJ["NJ-old"] = NJ["SR 1926"]NJ["SR-old"] = NJ["SR 1926"]

for k, v in pairs(NJ) do if k:find ("^SR %d") then v.name = NJ.SR.name v.link = NJ.SR.link v.abbr = NJ.SR.abbr endend

NJ["SRS 1926"] =

NJ["NJS 1926"] = NJ["SRS 1926"]

NJ.Byway =

-- add new types above this line if you want it to have the state highway browse and maintfor k, v in pairs(NJ) do if k:find ("^%a") then v.maint = "NJDOT" v.browse = "New Jersey State Highway Routes" v.browselinks = endend

NJ.NJTP =

NJ.NBEX =

NJ.PAEX =

NJ.GSP =

NJ.ACE =

for _,type in ipairs do NJ[type .. "2"] = end

NJ.ACBC =

NJ.PIP =

NJ.OD =

local countybrowse =

NJ.CR =

for _,type in ipairs do for _,auxType in ipairs do local spec = NJ[" aux "][auxType] NJ["CR-" .. auxType] = endend

NJ.PA = NJ.NY =

return NJ