blocks
5. NO emoji inside
6. Use - for lists
7. Function references:
name(args) — description
8. Escape bare < and > outside allowed tags
9. Add 🚀 Quick Reference as second section
10. Output only valid HTML
Let me transform the content:
The original has these sections (from the anchors):
- NAME
- SYNOPSIS
- DESCRIPTION
- CONSTRUCTOR
- METHODS
- PROPERTIES
- SEE ALSO
- AUTHOR
- COPYRIGHT
I need to:
1. Remove the original H1 line (Cache::Memory(3pm)... and the links)
2. Add H2 headings with emoji
3. Add Quick Reference section after NAME
4. Wrap all code in
5. Preserve structure
Let me also note: the original has `Cache::Memory->new(...)` which uses `>` - this is part of Perl syntax inside code blocks. Inside , the `>` is fine because it's not being parsed as HTML. But wait - the rule says "ANY < or > NOT part of an allowed HTML tag MUST be escaped". Inside , the content is text, so < and > need to be escaped as < and > to prevent them from being parsed as HTML.
Let me carefully escape all < and > inside blocks.
Looking at the code:
- `Cache::Memory->new(namespace => 'MyNamespace', ...)` - has `->` and `=>` - no ``
- `Chris Leishman ` - this has `` but it's not in a code block, it's the author line
Wait, let me re-check. The author line:
`Chris Leishman ` - this is NOT in a code block, it's a text paragraph. So I need to escape `` as `>`.
Actually, in the original it's:
`chris AT leishman.org`
This is the link format. I should preserve the `` tag and `` tag, and escape any bare ``.
Let me look at each section:
NAME section has: `Cache::Memory - Memory based implementation of the Cache interface`
This has `->` but no ``. Wait, no - `Cache::Memory` doesn't have any arrow. Let me re-read.
Actually `Cache::Memory` is just the module name, no `->`. Good.
SYNOPSIS:
```
use Cache::Memory;
my $cache = Cache::Memory->new( namespace => 'MyNamespace',
default_expires => '600 sec' );
```
This has `->` and `=>` but no ``. Inside , these need to be escaped only if they would be parsed as HTML. The `->` is fine, the `=>` is fine. There's no `` here.
DESCRIPTION: just text, no special chars to worry about.
CONSTRUCTOR:
```
my $cache = Cache::Memory->new( %options )
```
No ``.
PROPERTIES:
```
my $ns = $c->namespace();
$c->set_namespace( $namespace );
```
No ``.
AUTHOR:
Original: `chris AT leishman.org`
This is text content with embedded HTML tags. The ``, `` are allowed HTML tags. So I'll preserve them.
COPYRIGHT:
`Copyright (C) 2003-2006 Chris Leishman. All Rights Reserved.`
The `(C)` is fine, no ``.
Wait, the original has `Copyright (C) 2003-2006` - the (C) might be a copyright symbol that got mangled. I'll just keep it as text.
Let me also handle the Quick Reference. For this module, common use cases would be:
- Creating a cache instance
- Setting/getting values (but the API isn't detailed here, just referenced from Cache)
- Setting namespace
Let me build this out now.
Also, the original has `` anchors - I don't need to preserve these.
Let me check the original first line:
`Cache::Memory(3pm) User Contributed Perl Documentation Cache::Memory(3pm)`
This is the page header with the H1-style title. I should remove this entirely as instructed (NEVER use ).
Final footer:
`perl v5.32.0 2021-01-01 Cache::Memory(3pm)`
This is footer info. I'll convert it to a simple text or remove it. Actually, the rules don't say what to do with the footer. I'll keep it as a small note.
Let me now write the output:
```html
📛 NAME
Cache::Memory - Memory based implementation of the Cache interface
🚀 Quick Reference
Use Case Command Description
Create cache Cache::Memory->new(namespace => 'MyNamespace', default_expires => '600 sec')Initialize an in-memory cache with namespace and default TTL
Set namespace $c->set_namespace($namespace)Switch to a different caching store area
Get namespace $c->namespace()Retrieve the current namespace
📜 SYNOPSIS
use Cache::Memory;
my $cache = Cache::Memory->new( namespace => 'MyNamespace',
default_expires => '600 sec' );
See Cache for the usage synopsis.
📖 DESCRIPTION
The Cache::Memory class implements the Cache interface. This cache stores data on a per-process basis. This is the fastest of the cache implementations, but is memory intensive and data can not be shared between processes. It also does not persist after the process dies.
However data will remain in the cache until cleared or it expires. The data will be shared between instances of the cache object, a cache object going out of scope will not destroy the data.
🔧 CONSTRUCTOR
my $cache = Cache::Memory->new( %options )
The constructor takes cache properties as named arguments, for example:
my $cache = Cache::Memory->new( namespace => 'MyNamespace',
default_expires => '600 sec' );
See 'PROPERTIES' below and in the Cache documentation for a list of all available properties that can be set.
⚙️ METHODS
See Cache for the API documentation.
🏷️ PROPERTIES
Cache::Memory adds the property 'namespace', which allows you to specify a different caching store area to use from the default. All methods will work ONLY on the namespace specified.
my $ns = $c->namespace();
$c->set_namespace( $namespace );
For additional properties, see the Cache documentation.
🔗 SEE ALSO
Cache
✍️ AUTHOR
Chris Leishman <chris AT leishman.org>
Based on work by DeWitt Clinton <dewitt AT leishman.org>
📜 COPYRIGHT
Copyright (C) 2003-2006 Chris Leishman. All Rights Reserved.
This module is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either expressed or implied. This program is free software; you can redistribute or modify it under the same terms as Perl itself.
$Id: Memory.pm,v 1.9 2006/01/31 15:23:58 caleishm Exp $
perl v5.32.0 — 2021-01-01
```
Wait, I need to double-check the escaping. Inside , the `->` and `=>` are fine as raw text. But what about other characters? Let me check rule 13:
"ANY < or > NOT part of an allowed HTML tag (, ,
,
, , , , , ,