{"id":37907263,"url":"https://github.com/mygreen/splate","last_synced_at":"2026-01-16T17:13:20.539Z","repository":{"id":45079512,"uuid":"280787471","full_name":"mygreen/splate","owner":"mygreen","description":"splate is Java Library for 2Way-SQL template","archived":false,"fork":false,"pushed_at":"2024-02-02T22:28:47.000Z","size":1978,"stargazers_count":4,"open_issues_count":3,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-14T11:52:00.683Z","etag":null,"topics":["java","springframework","sql","sqltemplate"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mygreen.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-07-19T03:56:33.000Z","updated_at":"2022-12-27T23:43:06.000Z","dependencies_parsed_at":"2022-09-26T21:50:23.050Z","dependency_job_id":null,"html_url":"https://github.com/mygreen/splate","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/mygreen/splate","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygreen%2Fsplate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygreen%2Fsplate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygreen%2Fsplate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygreen%2Fsplate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mygreen","download_url":"https://codeload.github.com/mygreen/splate/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygreen%2Fsplate/sbom","scorecard":{"id":670733,"data":{"date":"2025-08-11","repo":{"name":"github.com/mygreen/splate","commit":"e8ad2899272a4f585e05c8d5f4453aead4ace9db"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.1,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/5 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/run_test.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/run_test.yml:27: update your workflow using https://app.stepsecurity.io/secureworkflow/mygreen/splate/run_test.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/run_test.yml:29: update your workflow using https://app.stepsecurity.io/secureworkflow/mygreen/splate/run_test.yml/master?enable=pin","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":10,"reason":"SAST tool detected","details":["Info: SAST configuration detected: Sonar","Warn: 0 commits out of 30 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"12 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-vmq6-5m68-f53m","Warn: Project is vulnerable to: GHSA-6v67-2wr5-gvf4","Warn: Project is vulnerable to: GHSA-pr98-23f8-jwxv","Warn: Project is vulnerable to: GHSA-36p3-wjmg-h94x","Warn: Project is vulnerable to: GHSA-hh26-6xwr-ggv7","Warn: Project is vulnerable to: GHSA-4gc7-5j7h-4qph","Warn: Project is vulnerable to: GHSA-4wp7-92pw-q264","Warn: Project is vulnerable to: GHSA-g5mm-vmx4-3rg7","Warn: Project is vulnerable to: GHSA-558x-2xjg-6232","Warn: Project is vulnerable to: GHSA-564r-hj7v-mcr5","Warn: Project is vulnerable to: GHSA-9cmq-m9j5-mvww","Warn: Project is vulnerable to: GHSA-wxqc-pxw9-g2p8"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-21T19:56:43.038Z","repository_id":45079512,"created_at":"2025-08-21T19:56:43.038Z","updated_at":"2025-08-21T19:56:43.038Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28480082,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T11:59:17.896Z","status":"ssl_error","status_checked_at":"2026-01-16T11:55:55.838Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","springframework","sql","sqltemplate"],"created_at":"2026-01-16T17:13:19.932Z","updated_at":"2026-01-16T17:13:20.533Z","avatar_url":"https://github.com/mygreen.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.github.mygreen/splate/badge.svg)](https://maven-badges.herokuapp.com/maven-central/com.github.mygreen/splate/)\n[![Javadocs](https://javadoc.io/badge/com.github.mygreen/splate.svg?color=blue)](https://javadoc.io/doc/com.github.mygreen/splate)\n[![build](https://github.com/mygreen/splate/actions/workflows/maven.yml/badge.svg)](https://github.com/mygreen/splate/actions/workflows/maven.yml)\n[![SonarQube](https://sonarcloud.io/api/project_badges/measure?project=com.github.mygreen%3Asplate\u0026metric=alert_status)](https://sonarcloud.io/dashboard?id=com.github.mygreen%3Asplate)\n\n# splate\n\n![logo](logo.png)\n\nsplate（エス・プレート）は、 **2Way-SQL** 機能のみを [S2JDBC](http://s2container.seasar.org/2.4/ja/s2jdbc.html) から分離し、使いやすくしたライブラリです。\n\nこのライブラリは、SpringFrameworkに依存しています。理由は以下の通りです。\n\n- SpringFrameworkに依存している理由として、普段、Javaで開発するときには、多くがSpringBootを利用しいる状況にあるためです。\n- そのため、無理にSpringFrameworkに依存しないように作ってもコード量が増えるだけで、あまりメリットがないと考えられます。\n- SpringFrameworkに依存しないで2Way-SQLを利用するならば、他の多くのライブラリ（ [Doma2](https://doma.readthedocs.io/) / [DBFlute](http://dbflute.seasar.org/) / [Mirage-SQL](https://github.com/mirage-sql/mirage) / [uroboroSQL](https://future-architect.github.io/uroborosql-doc/) ）が既に存在するので、そちらを利用することを検討した方がよいかもしれません。\n\n## Licensee\nApache2 License\n\n## Dependency\n\n- Java 11+\n- SpringFramework 5.0+\n- Slf4j 1.7+\n\n\n## Setup\n\nAdd dependency. ex) pom.xml\n\n```xml\n\u003cdependency\u003e\n\t\u003cgroupId\u003ecom.github.mygreen\u003c/groupId\u003e\n\t\u003cartifactId\u003esplate\u003c/artifactId\u003e\n\t\u003cversion\u003e0.3\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n## How to use\n\n1. Define SQL file.\n  ```sql\n  select * from employee\n  /*BEGIN*/\n  where\n  /*IF salaryMin != null*/\n  salary \u003e= /*salaryMin*/1000\n  /*END*/\n  /*IF salaryMax != null*/\n  and salary \u003c= /*salaryMax*/2000\n  /*END*/\n  /*END*/\n  ```\n2. Create instance the ``SqlTemplateEngine`` and parse SQL template file.\n  ```java\n  SqlTemplateEngine templateEngine = new SqlTemplateEngine();\n  SqlTemplate template = templateEngine.getTemplate(\"classpath:/sql/employee_select.sql\");\n  ```\n3. Create template parameter with ``SqlTemplateContext``.\n  ```java\n  public class SelectParam {\n      public BigDecimal salaryMin;\n      public BigDecimal salaryMax;\n  }\n  ```\n\n  ```java\n  // create parameter with JavaBean.\n  SelectParam param = new SelectParam();\n  param.salaryMin = new BigDecimal(1200);\n  param.salaryMax = new BigDecimal(1800);\n  \n  // create instance of SqlTemplateContext.\n  SqlTemplateContext templateContext = new BeanPropertySqlTemplateContext(param);\n  ```\n4. Evaluating SQL template.\n  ```java\n  ProcessResult result = template.process(templateContext);\n\n  // sql : select * from employee salary \u003e= ? and salary \u003c= ?\n  String sql = result.getSql();\n\n  // bind parameters\n  List\u003cObject\u003e params = result.getParameters();\n  ```\n\n## Documentation\n\n- Project information and manual.\n  - https://mygreen.github.io/splate/index.html\n- JavaDoc\n  - https://mygreen.github.io/splate/apidocs/index.html\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmygreen%2Fsplate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmygreen%2Fsplate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmygreen%2Fsplate/lists"}