Module:PD-EdictGov

--[=[ Implements Template:PD-EdictGov and related templates ]=]

local p = {} --p stands for package

local getArgs = require('Module:Arguments').getArgs local PD = require('Module:PD')

local EdictGov_text = " in the public domain in the U.S. because " .. PD.license_grammar({"it is an edict of a government", "they are edicts of a government"}) .. ", local or foreign. See § 313.6(C)(2) of the Compendium II: Copyright Office Practices. Such documents include &quot;legislative enactments, judicial decisions, administrative rulings, public ordinances, or similar types of official legal materials&quot; as well as &quot;any translation prepared by a government employee acting within the course of his or her official duties.&quot;"

function p._PD_EdictGov(args) local text = PD.license_scope .. EdictGov_text .. "\n\nThese do not include works of the Organization of American States, United Nations, or any of the UN specialized agencies. See Compendium III § 313.6(C)(2) and 17 U.S.C. 104(b)(5)." local warning = "A non-American governmental edict may still be copyrighted outside the U.S. Similar to, the above U.S. Copyright Office Practice does not prevent U.S. states or localities from holding copyright abroad, depending on foreign copyright laws and regulations." return PD.license({		['image'] = PD.PD_image,		['image_r'] = PD.US_flag_image,		['text'] = text,		['warning'] = warning,		['category'] = args.category or "PD-EdictGov"	}) end

function p.PD_EdictGov(frame) return p._PD_EdictGov(getArgs(frame)) end

function p._PD_ParticularGov(args) local text local image_r local warning local category local template = args.template if template == "PD-INGov" then text = table.concat({			PD.license_scope .. " the work of Government of India. Section 52(1)(q) of the Indian Copyright Act, 1957 allows for the reproduction or publication of",			"* any matter which has been published in any Official Gazette except an Act of a Legislature;",			"* any Act of a Legislature subject to the condition that such Act is reproduced or published together with any commentary thereon or any other original matter;",			"* the report of any committee, commission, council, board or other like body appointed by the government if such report has been laid on the Table of the Legislature, unless the reproduction or publication of such report is prohibited by the government;",			"* any judgement or order of a court, Tribunal or other judicial authority, unless the reproduction or publication of such judgement or order is prohibited by the court, the Tribunal or other judicial authority, as the case may be.", "The decision of the Supreme Court of India in &quot;Eastern Book Company & Ors vs D.B. Modak & Anr&quot; on 12 December, 2007 interpreted this section of the Act as making the material public domain." }, "\n")		image_r = "Emblem of India.svg"	elseif template == "Legislation-CAGov" then		image_r = "Flag of Canada.svg"		text = PD.license_scope .. " reproduced under the terms of the Reproduction of Federal Law Order for enactments of the Government of Canada. " .. PD.license_grammar({"This document is", "These documents are"}) .. " not an official version, and not endorsed by the Government of Canada."		warning = "Canadian legislation is under Crown Copyright pursuant to Section 12 of the Copyright Act for 50 years after the year of first publication. That section and the lack of modern case law make it unclear whether these documents remain protected by perpetual Crown rights and privileges after that term ends."	elseif template == "PD-DEGov" then		image_r = "Coat of arms of Germany.svg" text = PD.license_scope .. " in the public domain according to German copyright law because " .. PD.license_grammar({"it is","they are"}) .. " part of a statute, ordinance, official decree or judgment (official work) issued by a German federal or state authority or court (§ 5 Abs.1 UrhG)." warning = "Third-party translations are not covered by this licence." elseif template == "PD-ILGov" then image_r = "Coat of arms of Israel.svg" text = PD.license_scope .. " from Israel and " .. PD.license_grammar({"is", "are"}) .. " in the public domain because " .. PD.license_grammar({"it is a work that is", "they are works that are"}) .. " not subject to copyright under Section 6 of the Israeli Copyright Law.\n\n" text = text .. mw.getCurrentFrame:expandTemplate { ['title'] = 'blockquote', ['args'] = { "6. Official Publications\n\nNotwithstanding the provisions of Section 4, there will be no copyright pertaining to laws, regulations, Knesset publications or judicial decisions of a court or of a governmental agency that has adjudicative powers under the law." }		}	elseif template == "PD-NamibiaGov" then text = PD.license_scope .. " in the public domain because " .. PD.license_grammar({"it was", "they were"}) .. " created and first published in Namibia and is is a work of a legislative, administrative or legal nature, or an official translation thereof.\n\nAccording to the Copyright and Neighbouring Rights Protection Act, 1994, Section 15 part (8), &quot;No copyright shall subsist in the official text of any work of a legislative, administrative or legal nature, or an official translation thereof.&quot;" image_r = "Coat of arms of Namibia.svg" elseif template == "PD-VenezuelaGov" then text = PD.license_scope .. " in the public domain because " .. PD.license_grammar({"it is a work", "they are works"}) .. " of the Venezuelan government and according to the &quot;Law on Copyright&quot;, August 14, 1993, Part 1, Chapter 1, Section 1-4, &quot;The texts of laws, decrees, official regulations, public treaties, judicial decisions and other official acts shall not be protected by this Law.&quot;" image_r = "Coat of arms of Venezuela.svg" elseif template == "PD-CaliforniaGov" then image_r = "Seal of California.svg" text = PD.license_scope .. " the work of a State of California employee, taken or made during the course of that person's official duties, and " .. PD.license_grammar({"is", "are"}) .. " consequently in the public domain due to the California Public Records Act." elseif template == "PD-CambodiaGovDoc" then image_r = "Royal arms of Cambodia.svg" text = PD.license_scope .. " in the public domain because " .. PD.license_grammar({"it is a work", "they are works"}) .. " of the Royal Government of Cambodia (see Article 10 under Section 1: Works of the Law on Copyright and Related Rights of Cambodia).\n\nAccording to Article 10 of the Law on Copyright and Related Rights of Cambodia, the following works are not eligible for copyright:\n* Constitution, Law, Royal Decree, Sub-Decree, and other Regulations.\n* Proclamation (Prakas), decision, certificate, other instructed circulars issued by state organizations.\n* Court decision or other court warrants.\n* Translation of those materials mentioned in the preceding paragraphs (a), (b), and (c) of this article.\n* Idea, formality, method of operation, concept, principle, discovery or mere data, even if expressed, described, explained or embodied in any work." elseif template == "PD-DenmarkGov" then image_r = 'Coat of Arms of Denmark.svg' text = PD.license_scope .. " in the public domain because " .. PD.license_grammar({"it is", "they are"}) .. " a part of a decision or a statement by an authority or a public body of Denmark. Danish copyright law specifies that no copyright exists in such material (§ 9)." elseif template == "PD-IcelandGov" then image_r = 'Flag of Iceland.svg' text = PD.license_scope .. " in the public domain in Iceland because acts, regulations, administrative provisions, court rulings and similar official documents are not subject to copyright according to Icelandic copyright law, nor are official translations of such documents.\n\nThis is according to article 9 (English) in the Icelandic Höfundalög." elseif template == "PD-Egypt-official" then image_r = 'Coat of arms of Egypt (Official).svg' category = 'PD-EgyptGov' text = PD.license_scope .. " " .. mw.getCurrentFrame:expandTemplate { ['title'] = 'u', ['args'] = { "not an object of copyright" }		} .. " in Egypt because " .. PD.license_grammar({"it is an official document", "they are official documents"}) .. ". Regardless of their source or target language, all official documents are ineligible for protection in Egypt, including laws, regulations, resolutions and decisions, international conventions, court decisions, award of arbitrators and decisions of administrative committees having judicial competence. (Article 141 of Intellectual Property Law 82 of 2002)" elseif template then return PD.error_text("Module:PD-EdictGov error: " .. template .. " is not a template supported by _PD_ParticularGov.", nil) else return PD.error_text("Module:PD-EdictGov error: _PD_ParticularGov requires a template to be specified.", nil) end return PD.license({		['image'] = PD.PD_image,		['image_r'] = image_r,		['text'] = text .. "\n\n" .. PD.license_scope .. " also" .. EdictGov_text,		['category'] = args.category or category or template,		['warning'] = warning	}) end

function p.PD_ParticularGov(frame) return p._PD_ParticularGov(getArgs(frame)) end

return p