From bf543f5bebbf8f32be979654836e8720ec7f0431 Mon Sep 17 00:00:00 2001 From: Garvin Hicking Date: Thu, 16 Jan 2025 10:27:39 +0100 Subject: [PATCH] [TASK] Followup- to improve "Services" chapter (#5219) Remove possible misread that service classes "should not" return data. This is explained later on in detail how data is processed. Related: #5211 --- Documentation/CodingGuidelines/PhpArchitecture/Services.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/CodingGuidelines/PhpArchitecture/Services.rst b/Documentation/CodingGuidelines/PhpArchitecture/Services.rst index e4c89bad7..da2b78c41 100644 --- a/Documentation/CodingGuidelines/PhpArchitecture/Services.rst +++ b/Documentation/CodingGuidelines/PhpArchitecture/Services.rst @@ -26,8 +26,8 @@ data objects (DO). This distinction has gained significance with the introduction of :ref:`dependency injection ` in the TYPO3 core. -A well-designed service class comprise of one or more methods that process data. -These methods may not return any value, acting as a data sink. For example, a +A well-designed service class comprise of one or more methods that process +data, or just provide a data sink. For example, a mailer service might take a mail data object to send it. Conversely, service methods often return new or modified data based on input. A typical example is a repository service that accepts an identifier (e.g. the uid of a product) and returns