Agent skill

Java Oop Solid Design

by makifbaysal in makifbaysal/tasktrooper

A skill your agent uses when modelling a rich domain in Java - SOLID principles, encapsulated entities that enforce their own invariants, and value objects over primitives

Apache-2.0Auto-check passedDevelopment

Install Java Oop Solid Design

skills CLI
$ npx skills add makifbaysal/tasktrooper --skill java-oop-solid-design -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install makifbaysal/tasktrooper java-oop-solid-design --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/makifbaysal/tasktrooper.git skills-src && mkdir -p .claude/skills && cp -r skills-src/catalog/agents/backend-developer/skills/java-oop-solid-design .claude/skills/java-oop-solid-design && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
java-oop-solid-design
GitHub stars
109
Token cost
~1k tokens
SKILL.md length
408 words
Files
1
Skills in repo
99
Repo updated
First seen
Licence
Apache-2.0

At a glance

A skill your agent uses when modelling a rich domain in Java - SOLID principles, encapsulated entities that enforce their own invariants, and value objects over primitives

  • Modelling a rich domain in Java - SOLID principles
  • SKILL.md covers Overview, SOLID, concretely, Encapsulation over anemic models and Value objects over primitives, plus 3 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md
  • Encapsulated entities that enforce their own invariants

What it does

Java Oop Solid Design is an agent skill from makifbaysal/tasktrooper. Use when modelling a rich domain in Java - SOLID principles, encapsulated entities that enforce their own invariants, and value objects over primitives

Its SKILL.md is about 1k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Design patterns. It works with Java. The repository describes itself as: Local-first agent platform: board + role agents + agent CLI runs (Claude Code, Cursor, Antigravity, OpenCode) or local and API models (Ollama, LM Studio), all on your own Mac. The licence is Apache-2.0.

When your agent uses it

  • Modelling a rich domain in Java - SOLID principles
  • Encapsulated entities that enforce their own invariants
  • Value objects over primitives

Example prompts

  • “/java-oop-solid-design”

What it can do on your machine

Read from SKILL.md and the folder at commit f3d59b5. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are java).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Java Oop Solid Design loads about 1k tokens when it runs. Until then it costs about 43 tokens; SKILL.md has 408 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~43
When it runs · the whole SKILL.md, loaded when a task matches
~1k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from makifbaysal/tasktrooper at commit f3d59b5, republished under its Apache-2.0 licence (© makifbaysal). 408 words, ~1,014 tokens.

Download SKILL.mdSave it as .claude/skills/java-oop-solid-design/SKILL.md (or your agent's skills folder).
name
java-oop-solid-design
description
Use when modelling a rich domain in Java - SOLID principles, encapsulated entities that enforce their own invariants, and value objects over primitives
category
architecture
tech_stack
Java

Java OOP & SOLID Design

Overview

Java is chosen precisely when the domain is rich (see java-vs-go-decision). That value is only realized if you model it with real objects that protect their invariants — not anemic data bags with a pile of setters and logic scattered in services.

Core principle: Objects own their invariants. If a rule about an entity can be violated from outside the entity, the model is broken.

SOLID, concretely

  • S — Single Responsibility: one reason to change per class. A class that parses HTTP, applies business rules, and writes SQL is three classes.
  • O — Open/Closed: extend behavior via new types/strategies, not by editing a growing switch. New payment method → new PaymentMethod implementation, not another case.
  • L — Liskov: a subtype must honor the supertype's contract. If Square extends Rectangle breaks setWidth, the hierarchy is wrong — prefer composition.
  • I — Interface Segregation: many small role interfaces over one fat one. A caller that needs read shouldn't depend on write.
  • D — Dependency Inversion: services depend on interfaces (ports), not concrete adapters. Inject the interface via the constructor.

Encapsulation over anemic models

java
// ❌ anemic: invariant lives nowhere, anyone can break it
class Task {
    public String title;      // no bound enforced
    public Status status;
}
task.title = "x".repeat(500); // invalid state, no guard

// ✅ rich: the entity enforces its own rules
public final class Task {
    private final TaskId id;
    private String title;
    private Status status;

    private Task(TaskId id, String title) { this.id = id; this.title = title; }

    public static Task create(String title) {
        if (title == null || title.isBlank() || title.length() > 200)
            throw new InvalidTaskTitle(title);
        return new Task(TaskId.newId(), title);
    }

    public void rename(String title) { /* same guard, reused */ }
    public void complete() {
        if (status == Status.DONE) throw new IllegalTransition("already done");
        this.status = Status.DONE;
    }
    // getters, no public setters
}

Value objects over primitives

Wrap meaningful primitives: TaskId, Email, Money — not raw String/long/BigDecimal. A TaskId can't be accidentally passed where a UserId is expected, and validation lives in one place. Java record makes these cheap.

Show full SKILL.md (195 more words)Show less

Prefer

  • record for immutable value objects and DTOs.
  • sealed interfaces + pattern matching for closed hierarchies (states, commands).
  • Immutability by default; expose behavior methods, not setters.
  • Throw domain exceptions (InvalidTaskTitle) mapped to HTTP status at the boundary — not raw IllegalArgumentException leaking out.

Prefer a sealed interface + exhaustive switch pattern matching (final since Java 21) for a closed set of states or commands over a type enum plus if/instanceof chains — the compiler then refuses to let a new case go unhandled.

Common Mistakes

  • Public setters that let callers build invalid state.
  • Business rules in the service that should be on the entity.
  • String/long everywhere instead of value objects.
  • A god-service with dozens of methods and no domain objects.
  • Lombok @Data/@EqualsAndHashCode on a JPA entity — it pulls in lazy associations (forcing a load, or crashing outside the session) and generates a mutable, settable id that breaks equals/hashCode once the entity is persisted. Write equals/hashCode on the id only, or skip Lombok on entities.

Red Flags

  • An entity with only getters/setters and no behavior.
  • The same validation copy-pasted in two services → it belongs on the entity/value object.
  • A switch over a type enum that grows every feature → missing polymorphism.

© makifbaysal, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in catalog/agents/backend-developer/skills/java-oop-solid-design of makifbaysal/tasktrooper.

Open the folder on GitHubat commit f3d59b5

Compare with similar skills

Java Oop Solid Design next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Java Oop Solid Design compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Java Oop Solid Design this skillmakifbaysal/tasktrooper109—~1kAutomated safety check: PassApache-2.0
Java Architecture Reviewdecebals/claude-code-java7501 repos~2.2kAutomated safety check: PassMIT
Java Design Patterns Referencedecebals/claude-code-java7501 repos~4.4kAutomated safety check: PassMIT
Clean Code Principlesdecebals/claude-code-java750—~3.4kAutomated safety check: PassMIT
Solid Principlesdecebals/claude-code-java750—~4.2kAutomated safety check: PassMIT
Hexagonal Architecture Layers JavaGentleman-Programming/Gentleman-Skills657—~1kAutomated safety check: PassMIT

Similar skills

  • Java Architecture Review

    decebals/claude-code-java

    Reviews a Java project's architecture at the macro level: package structure, module boundaries, dependency direction and layering.

    750 GitHub starsUsed in 1 repo~2.2k tokens
    DevelopmentAuto-check passed
  • Java Design Patterns Reference

    decebals/claude-code-java

    A practical Java reference for Builder, Factory, Singleton, Strategy, Observer and other patterns, with a table matching problems to patterns.

    750 GitHub starsUsed in 1 repo~4.4k tokens
    DevelopmentAuto-check passed
  • Clean Code Principles

    decebals/claude-code-java

    Covers Clean Code principles for Java: DRY, KISS and YAGNI with before-and-after examples, plus naming conventions for variables and booleans.

    750 GitHub stars~3.4k tokensUpdated 1 mo ago
    DevelopmentAuto-check passed
  • Solid Principles

    decebals/claude-code-java

    SOLID principles checklist with Java examples. An agent skill from decebals/claude-code-java.

    750 GitHub stars~4.2k tokensUpdated 1 mo ago
    DevelopmentAuto-check passed
  • Hexagonal Architecture Layers Java

    Gentleman-Programming/Gentleman-Skills

    Hexagonal architecture layering for Java services with strict boundaries.

    657 GitHub stars~1k tokensUpdated 6 mo ago
    DevelopmentAuto-check passed
  • 125 Java Concurrency

    jabrena/plinth

    A skill your agent uses when you need to apply Java concurrency best practices — including thread safety fundamentals, ExecutorService thread pool management, concurrent design patterns like…

    445 GitHub stars~1.1k tokensUpdated today
    DevelopmentAuto-check passed

More from makifbaysal/tasktrooper

All 99 skills in this repo
  • API Contract Testing

    makifbaysal/tasktrooper

    A skill your agent uses when a task adds or changes an HTTP endpoint, its request/response shape, status codes, auth or error format - the request matrix, curl templates and what counts as a…

    109 GitHub starsUsed in 1 repo~754 tokens
    Auto-check passed
  • Acceptance Criteria Gwt

    makifbaysal/tasktrooper

    A skill your agent uses when writing acceptance criteria for a task - express each as an observable Given/When/Then that QA can execute, including negative cases

    109 GitHub stars~1.7k tokensUpdated yesterday
    Auto-check passed
  • Accessibility Check

    makifbaysal/tasktrooper

    A skill your agent uses when a task changes any screen, form, dialog, menu or control - Lighthouse/axe scan of the changed screens, a keyboard walk, and the thresholds that fail a task

    109 GitHub stars~1k tokensUpdated yesterday
    Auto-check passed
  • Analiz Gate

    makifbaysal/tasktrooper

    A skill your agent uses when deciding whether a request needs an analiz task before implementation - the conditions that require the architect's analysis versus going straight to implementation

    109 GitHub stars~641 tokensUpdated yesterday
    Auto-check passed
  • Analiz HTML Report

    makifbaysal/tasktrooper

    A skill your agent uses when you write or revise the analiz deliverable - the ONE self-contained HTML report (spec and plan as sections) a human reviews passage by passage

    109 GitHub stars~3.9k tokensUpdated yesterday
    Auto-check passed
  • Analiz Human Review Gate

    makifbaysal/tasktrooper

    A skill your agent uses when you finish an analiz report - the human must approve the analysis before any implementation task is created, via the analizreview column

    109 GitHub stars~2.2k tokensUpdated yesterday
    Auto-check passed

Works with

Categories

Questions about Java Oop Solid Design

What does Java Oop Solid Design do?

A skill your agent uses when modelling a rich domain in Java - SOLID principles, encapsulated entities that enforce their own invariants, and value objects over primitives. Java Oop Solid Design is an agent skill from makifbaysal/tasktrooper.

When should I use Java Oop Solid Design?

Java Oop Solid Design fits situations like: modelling a rich domain in Java - SOLID principles; encapsulated entities that enforce their own invariants; value objects over primitives.

How do I install Java Oop Solid Design in Claude Code?

Run `npx skills add makifbaysal/tasktrooper --skill java-oop-solid-design -a claude-code`. Or copy the skill folder (catalog/agents/backend-developer/skills/java-oop-solid-design in makifbaysal/tasktrooper) into .claude/skills/java-oop-solid-design in your project. Claude Code loads it when a task matches its description.

How do I install Java Oop Solid Design in Codex?

Run `npx skills add makifbaysal/tasktrooper --skill java-oop-solid-design -a codex`. Or copy the skill folder (catalog/agents/backend-developer/skills/java-oop-solid-design in makifbaysal/tasktrooper) into .agents/skills/java-oop-solid-design in your project. Codex loads it when a task matches its description.

Can I use Java Oop Solid Design in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add makifbaysal/tasktrooper --skill java-oop-solid-design -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/java-oop-solid-design, .gemini/skills/java-oop-solid-design, .github/skills/java-oop-solid-design and .opencode/skills/java-oop-solid-design in your project.

What does Java Oop Solid Design need to run?

SKILL.md names no scripts, command-line tools or credentials: Java Oop Solid Design is instructions for the agent only.

Does Java Oop Solid Design access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Java Oop Solid Design safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Java Oop Solid Design use?

Java Oop Solid Design is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Java Oop Solid Design use?

About 1k tokens (SKILL.md is roughly 4.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Java Oop Solid Design?

Skills that share tags, products or a category with Java Oop Solid Design: Java Architecture Review (decebals/claude-code-java, 750 stars), Java Design Patterns Reference (decebals/claude-code-java, 750 stars), Clean Code Principles (decebals/claude-code-java, 750 stars) and Solid Principles (decebals/claude-code-java, 750 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Java Oop Solid Design?

makifbaysal (a GitHub user) maintains it in makifbaysal/tasktrooper, which has 109 GitHub stars. The repository holds 99 skills in this directory. The repository was last updated on October 6, 2026.

Source: makifbaysal/tasktrooper on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.