Module:bnt-headword

Hello, you have come here looking for the meaning of the word Module:bnt-headword. In DICTIOUS you will not only get to know all the dictionary meanings for the word Module:bnt-headword, but we will also tell you about its etymology, its characteristics and you will know how to say Module:bnt-headword in singular and plural. Everything you need to know about the word Module:bnt-headword you have here. The definition of the word Module:bnt-headword will help you to be more precise and correct when speaking or writing your texts. Knowing the definition ofModule:bnt-headword, as well as those of other words, enriches your vocabulary and provides you with more and better linguistic resources.

This module needs documentation.
Please document this module by describing its purpose and usage on the documentation page.

local export = {}

local lang = require("Module:languages").getByCode("bnt-pro")


function export.noun(frame)
	local params = {
		 = {},
		 = {},
		 = {},
		}
	
	local args = require("Module:parameters").process(frame:getParent().args, params)
	
	local data = {lang = lang, pos_category = "nouns", categories = {}, heads = {args}, genders = {args or "?"}, inflections = {}}
	
	local prefixes = {
		 =  {"mʊ̀"},
		 = {""},
		 =  {"bà"},
		 =  {"mʊ̀"},
		 =  {"mɪ̀"},
		 =  {"ì"},
		 =  {"mà"},
		 =  {"kɪ̀"},
		 =  {"bì"},
		 =  {"n", "m"},
		 = {"n", "m"},
		 = {"dʊ̀"},
		 = {"kà"},
		 = {"tʊ̀"},
		 = {"bʊ̀"},
		 = {"kʊ̀"},
		 = {"pà"},
		 = {"kʊ̀"},
		 = {"mʊ̀"},
		 = {"pì"}
	}
	
	local stem = mw.title.getCurrentTitle().subpageText
	
	if args then
		for key, prefix in ipairs(prefixes]) do
			if mw.ustring.find(stem, "^" .. prefix) then
				stem = stem:gsub("^" .. prefix, "")
				break
			end
		end
		
		table.insert(data.categories, lang:getCanonicalName() .. " class " .. args .. " nouns")
	end
	
	data.sort_key = lang:makeSortKey(stem)
	
	if args then
		local plural = prefixes] .. stem
		
		if args == "9" or args == "10" then
			if mw.ustring.find(stem, "^") then
				plural = "m" .. stem
			end
		end
		
		table.insert(data.inflections, {label = "plural", {term = "*" .. plural, genders = {"c" .. args}}})
	end
	
	return require("Module:headword").full_headword(data)
end


return export