<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>Override core class</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=119879011" />
  <subtitle>Override core class</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=119879011</id>
  <updated>2026-04-04T20:48:44Z</updated>
  <dc:date>2026-04-04T20:48:44Z</dc:date>
  <entry>
    <title>RE: Override core class</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119884464" />
    <author>
      <name>Olaf Kock</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119884464</id>
    <updated>2020-09-02T12:11:27Z</updated>
    <published>2020-09-02T12:11:27Z</published>
    <summary type="html">&lt;div class="quote-title"&gt;Daniel G:&lt;/div&gt;&lt;blockquote&gt;&lt;br /&gt;Hi.&lt;br /&gt;I am working with Liferay 7.1. I want to override one core class: HtmlBBCodeTranslatorImpl&lt;br /&gt;&lt;a href="https://github.com/liferay/liferay-portal/blob/7.1.x/modules/apps/message-boards/message-boards-parser-bbcode/src/main/java/com/liferay/message/boards/parser/bbcode/internal/HtmlBBCodeTranslatorImpl.java"&gt;https://github.com/liferay/liferay-portal/blob/7.1.x/modules/apps/message-boards/message-boards-parser-bbcode/src/main/java/com/liferay/message/boards/parser/bbcode/internal/HtmlBBCodeTranslatorImpl.java&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;is there any option of doing it without override the entire module and place it in override? Any help you can give me would be very appreciated&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;There might be, but you&amp;#39;ll need to stop thinking in terms of &amp;#34;overriding&amp;#34;. Looking at the code you link, it&amp;#39;s a &lt;a href="https://github.com/liferay/liferay-portal/blob/7.1.x/modules/apps/message-boards/message-boards-parser-bbcode/src/main/java/com/liferay/message/boards/parser/bbcode/internal/HtmlBBCodeTranslatorImpl.java#L48"&gt;proper declarative service&lt;/a&gt;, and while the &amp;#34;internal&amp;#34; package and the &amp;#34;Impl&amp;#34; class name suggest that it&amp;#39;s well locked away, nothing keeps you from implementing another service that does what you need. &lt;br /&gt;I haven&amp;#39;t tried it for this particular service, but &lt;a href="https://university.liferay.com/osgi-basics/180396"&gt;this and the following chapters in OSGi Basics&lt;/a&gt; (free registration / sign in required) might help you to provide such an alternative implementation. Of course, Liferay&amp;#39;s implementation might use quite a bit of more internal code that you won&amp;#39;t have access to, but that would be the next problem.&lt;br /&gt;Sometimes, module overrides aren&amp;#39;t the best maintainable option, sometimes they are. Try both, then judge which solution you expect to be the best maintainable one under the circumstances (code dependencies) that you find.</summary>
    <dc:creator>Olaf Kock</dc:creator>
    <dc:date>2020-09-02T12:11:27Z</dc:date>
  </entry>
  <entry>
    <title>Override core class</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119879010" />
    <author>
      <name>Daniel G</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119879010</id>
    <updated>2020-09-02T07:21:13Z</updated>
    <published>2020-09-02T07:21:13Z</published>
    <summary type="html">Hi.&lt;br /&gt;I am working with Liferay 7.1. I want to override one core class: HtmlBBCodeTranslatorImpl&lt;br /&gt;&lt;a href="https://github.com/liferay/liferay-portal/blob/7.1.x/modules/apps/message-boards/message-boards-parser-bbcode/src/main/java/com/liferay/message/boards/parser/bbcode/internal/HtmlBBCodeTranslatorImpl.java"&gt;https://github.com/liferay/liferay-portal/blob/7.1.x/modules/apps/message-boards/message-boards-parser-bbcode/src/main/java/com/liferay/message/boards/parser/bbcode/internal/HtmlBBCodeTranslatorImpl.java&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;is there any option of doing it without override the entire module and place it in override? Any help you can give me would be very appreciated&lt;br /&gt;Thanks in advance</summary>
    <dc:creator>Daniel G</dc:creator>
    <dc:date>2020-09-02T07:21:13Z</dc:date>
  </entry>
</feed>
