<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://cellan.joemonson.com/index.php?action=history&amp;feed=atom&amp;title=Module%3AArticle_history%2FCategory</id>
	<title>Module:Article history/Category - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://cellan.joemonson.com/index.php?action=history&amp;feed=atom&amp;title=Module%3AArticle_history%2FCategory"/>
	<link rel="alternate" type="text/html" href="http://cellan.joemonson.com/index.php?title=Module:Article_history/Category&amp;action=history"/>
	<updated>2026-10-25T20:14:52Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.0</generator>
	<entry>
		<id>http://cellan.joemonson.com/index.php?title=Module:Article_history/Category&amp;diff=10313&amp;oldid=prev</id>
		<title>Cellan3: Created page with &quot;------------------------------------------------------------------------------- -- Category class -- This module makes a Category class for use in Module:Article history. -- It provides a unified interface for the creation of category links. With -- this class, categories can passed between objects without concerns about -- interoperability and still have their values and sort keys easily -- accessible. ----------------------------------------------------------------...&quot;</title>
		<link rel="alternate" type="text/html" href="http://cellan.joemonson.com/index.php?title=Module:Article_history/Category&amp;diff=10313&amp;oldid=prev"/>
		<updated>2025-04-10T22:22:01Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;------------------------------------------------------------------------------- -- Category class -- This module makes a Category class for use in &lt;a href=&quot;/index.php/Module:Article_history&quot; title=&quot;Module:Article history&quot;&gt;Module:Article history&lt;/a&gt;. -- It provides a unified interface for the creation of category links. With -- this class, categories can passed between objects without concerns about -- interoperability and still have their values and sort keys easily -- accessible. ----------------------------------------------------------------...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;-------------------------------------------------------------------------------&lt;br /&gt;
-- Category class&lt;br /&gt;
-- This module makes a Category class for use in [[Module:Article history]].&lt;br /&gt;
-- It provides a unified interface for the creation of category links. With&lt;br /&gt;
-- this class, categories can passed between objects without concerns about&lt;br /&gt;
-- interoperability and still have their values and sort keys easily&lt;br /&gt;
-- accessible.&lt;br /&gt;
-------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local checkType = require(&amp;#039;libraryUtil&amp;#039;).checkType&lt;br /&gt;
local CATEGORY_NS_TEXT = mw.site.namespaces[14].name&lt;br /&gt;
&lt;br /&gt;
local Category = {}&lt;br /&gt;
Category.__index = Category&lt;br /&gt;
&lt;br /&gt;
function Category.new(category, sortKey)&lt;br /&gt;
	checkType(&amp;#039;Category.new&amp;#039;, 1, category, &amp;#039;string&amp;#039;)&lt;br /&gt;
	checkType(&amp;#039;Category.new&amp;#039;, 2, sortKey, &amp;#039;string&amp;#039;, true)&lt;br /&gt;
	local obj = setmetatable({}, Category)&lt;br /&gt;
	obj.category = category&lt;br /&gt;
	obj.sortKey = sortKey&lt;br /&gt;
	return obj&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function Category:__tostring()&lt;br /&gt;
	if self.sortKey then&lt;br /&gt;
		return string.format(&lt;br /&gt;
			&amp;#039;[[%s:%s|%s]]&amp;#039;,&lt;br /&gt;
			CATEGORY_NS_TEXT,&lt;br /&gt;
			self.category,&lt;br /&gt;
			self.sortKey&lt;br /&gt;
		)&lt;br /&gt;
	else&lt;br /&gt;
		return string.format(&lt;br /&gt;
			&amp;#039;[[%s:%s]]&amp;#039;,&lt;br /&gt;
			CATEGORY_NS_TEXT,&lt;br /&gt;
			self.category&lt;br /&gt;
		)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return Category&lt;/div&gt;</summary>
		<author><name>Cellan3</name></author>
	</entry>
</feed>