Module:InfoboxDataClass

local lang = mw.getLanguage('en') local m_team = require('Module:Team') local m_region = require('Module:Region') local m_country = require('Module:Country') local social = require('Module:Infobox/Social') local teamhist = require('Module:Infobox/TeamHist') local util_infobox = require('Module:InfoboxUtil') local util_html = require('Module:HtmlUtil') local util_cargo = require('Module:CargoUtil') local util_table = require('Module:TableUtil') local util_text = require("Module:TextUtil")

local Class = require('Module:LuaClassSystem').class

local p = Class

p.LAYOUT = { sections = { }, contents = { { },	},	i18n = {} }

p.NOIMAGE = 'Unknown Infobox Image - Player.png'

function p:init(args) self:castArgs(args) local processed = self:getProcessed(args) local settings = self:getSettings(args, processed) if self.type then self.LAYOUT.i18nFile = 'Infobox/' .. self.type end return { display = self:getDisplay(args, processed), cargo = self:getCargo(args, processed), settings = settings, categories = self:getCategories(args, processed), variables = self:getVariables(args, processed), layout = self.LAYOUT, } end

function p:castArgs(args) end

function p:getProcessed(args) local tbl = { pagename = mw.title.getCurrentTitle.text, }	return tbl end

function p:getSettings(args, processed) local ret = { lc = processed.lc, nocargo = mw.title.getCurrentTitle.nsText ~= '' or args.nocargo, nocat = mw.title.getCurrentTitle.nsText ~= '' or args['no-cat'], }	return ret end

function p:getDisplay(args, processed) local tbl = {} return tbl end

function p:getCargo(args, processed) local title = args._title or processed.title or mw.title.getCurrentTitle.text local tbl = { {			_table = 'Entities', Entity = title, EntityPage = mw.title.getCurrentTitle.text, EntityType = self.type, IsLowercase = lang:lcfirst(title) == title, DisambigSentence = self:getDisambigSentence(args, processed), }	}	return tbl end

function p:getDisambigSentence(args, processed) return ('%s (%s)'):format(		util_text.intLinkOrText(mw.title.getCurrentTitle.text, args._title or processed.title),		self.type	) end

function p:getCategories(args, processed) local tbl = {} return tbl end

function p:getVariables(args, processed) local tbl = {} return tbl end

return p