Delphi-PRAXiS
Seite 1 von 3  1 23      

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Sonstige Werkzeuge (https://www.delphipraxis.net/63-sonstige-werkzeuge/)
-   -   Mehrsprachige Quellcode Documentation - Ob & Wie? (https://www.delphipraxis.net/187585-mehrsprachige-quellcode-documentation-ob-wie.html)

Mavarik 11. Dez 2015 13:51

Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Hallo Zusammen...

Sourcode Documentation ist ja i.d.R. auf englisch..

Delphi-Quellcode:
   {$REGION 'Documentation'}
   /// <summary>
   ///   Class Information
   /// </summary>
   {$ENDREGION}
Ich stelle mir gerade die Frage, ob es nötig ist, diese auch auf deutsch zu erstellen. Mal abgesehen davon, dass ich kein Tool kenne, welches das sofort machen kann...

Man könnte natürlich externe XML Dateien erzeugen und die dann übersetzen...

Hierbei geht es nicht darum eigene Projekte zu dokumentieren, sondern um eine Sourcecode-Sammlung für andere Developer.

Ist es nötig? Wie haltet Ihr das...?

Mavarik :coder:

sh17 11. Dez 2015 13:55

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Wenn die Hauptsprache deutsch ist, warum nicht einfach deutsch rein schreiben?

jobo 11. Dez 2015 14:02

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Also wenn ich sonst alles erledigt habe, dann denke ich vielleicht mal über Dokumentation in einer 2. Sprache nach. ;)

TiGü 11. Dez 2015 14:37

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Warum willst du sie denn auf deutsch übersetzen?

Mavarik 11. Dez 2015 15:54

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Zitat:

Zitat von TiGü (Beitrag 1324119)
Warum willst du sie denn auf deutsch übersetzen?

Aus dem gleichen Grund warum ME auf den DelphiTagen DavidI immer übersetzt hat.

p80286 11. Dez 2015 15:59

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Zitat:

Zitat von Mavarik (Beitrag 1324108)
Hallo Zusammen...

Sourcode Documentation ist ja i.d.R. auf englisch..

Ist es nötig? Wie haltet Ihr das...?

a)Kommentare? wer liest die?
b)Die sind wie Freitextfelder in Datenbanken, vollkommen überflüssig!

Aber im Ernst welchem Zweck sollen sie dienen?
Meine Kommentare sind während der Entwicklung nur Kauderwelsch und sollte dann irgendwann einmal ein Programmteil halbwegs stabil sein, dann wird das Kauderwelsch durch einen englischen Kommentar ersetzt, damit (beinahe) jeder versteht worum es geht. Wobei Selbstverständlichkeiten nicht dokumentiert werden müssen, aber über das was selbstverständlich ist, hat wohl jeder eine eigene Meinung.

Gruß
K-H

P.S.
Freie Rede und geschriebener Kommentar - da gibt es aber leicht Unterschiede in der Verständlichkeit!

Mavarik 11. Dez 2015 16:17

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Zitat:

Zitat von p80286 (Beitrag 1324136)
a)Kommentare? wer liest die?

Ich habe nicht von Kommentaren gesprochen, sondern von Dokumentation...

Kleines Beispiel aus System.Sysutils

Delphi-Quellcode:
    TMultiWaitEventClass = class of TMultiWaitEvent;
  private
    class procedure FreeAndNil(var Obj); static; inline;
    class function DoWait(const Events: array of TMultiWaitEvent; WaitAll: Boolean; Index: PInteger; Event: PMultiWaitEvent; Timeout: Cardinal): TWaitResult; static;
    function WaiterExpired(var Info: TWaitInfo): Boolean;
    procedure RemoveExpiredWaiters;
  protected class var
    ///  <summary>
    ///    This class variable will be set by a single descendent. The expectation is that one and only one descedent
    ///    of this class exists. That one descendent provides the actual implementation. This class variable is
    ///    used by the static class function Create to construct an instance of that one class that implements the
    ///    needed functionality.
    ///  </summary>
    FMultiEventType: TMultiWaitEventClass;
  protected
    ///  <summary>
    ///    Abstract virtual class overridden in descendant classes to create the proper type for the instance.
    ///  </summary>
    class function CreateInstance: TMultiWaitEvent; virtual; abstract;
    ///  <summary>
    ///    Since This unit doesn't cannot use System.SysUtls, this virtual allows descendants which do have access to
    ///    System.SysUtils to provide a means for this base ancestor class to raise exceptions when validating arguments.
    ///  </summary>
    class procedure ArgumentException; virtual; abstract;
    ///  <summary>
    ///    Since This unit doesn't cannot use System.Classes, this virtual allows descendants which do have access to
    ///    System.Classes to provide a means for this base ancestor to call System.Classes.TThread.GetTickCount.
    ///  </summary>
    class function GetTickCount: Cardinal; virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. This explicitly locks this specific instance.
    ///  </summary>
    procedure Lock; virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. This explicitly unlocks this specific instance.
    ///  </summary>
    procedure Unlock; virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. This must <strong>atomically</strong> set the state of the event.
    ///  </summary>
    procedure AtomicSetEventState(State: Boolean); virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. Notifies all current waiters this event is signaled.
    ///  </summary>
    procedure NotifyWaiters; virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. Clears the storage used for the waiters.
    ///  </summary>
    procedure ClearWaiters; virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. Add a new waiter to the list of waiters.
    ///  </summary>
    procedure PushWaiter(const Waiter: TWaitInfo); virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. Removed a waiter from the list of waiters.
    ///  </summary>
    procedure RemoveWaiter(Index: Integer); virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. Returns the current number of waiters in the list of waiters.
    ///  </summary>
    function GetWaiterCount: Integer; virtual; abstract;
    ///  <summary>
    ///    Overridden in descendents. Returns the index'th waiter from the waiter list.
    ///  </summary>
    function GetWaiter(Index: Integer): PWaitInfo; virtual; abstract;
    /// <summary>
    ///    Current number of threads waiting on this event.
    /// </summary>
    property WaiterCount: Integer read GetWaiterCount;
    /// <summary>
    ///    Array of PWaitInfo references which contain information about each waiting thread.
    /// </summary>
    property Waiters[Index: Integer]: PWaitInfo read GetWaiter;
  public
    ///  <summary>
    ///    Rather than use a constructor which will create an instance of <strong>this</strong> class, this will
    ///    return an instance of the registered descendent type that provides the actual implementation.
    ///  </summary>
    class function Create: TMultiWaitEvent; static;
    destructor Destroy; override;

    /// <summary>Wait for this event instance to be signaled or Timeout is reached.</summary>
    function WaitFor(Timeout: Cardinal = INFINITE): TWaitResult; virtual; abstract;
    /// <summary>Explicitly set the event as signaled. This procedure is typically called by the implementation of
    ///    a specific IAsyncResult.
    /// </summary>
    procedure SetEvent;
    /// <summary>Explicitly reset the event as unsignaled. This procedure is rarely if ever called. If it is called, it
    ///    is called by the implementation of a specific IAsyncResult.
    /// </summary>
    procedure ResetEvent;

    /// <summary>Wait until all of the indicated TMultiWaitEvents are signaled or Timeout is reached</summary>
    class function WaitForAll(const Events: array of TMultiWaitEvent; Timeout: Cardinal = INFINITE): TWaitResult; static;
    /// <summary>Wait until at least one of the indicated TMultiWaitEvents are signaled or Timeout is reached</summary>
    class function WaitForAny(const Events: array of TMultiWaitEvent; Timeout: Cardinal = INFINITE): TWaitResult; overload; static;
    /// <summary>Wait until at least one of the indicated TMultiWaitEvents are signaled or Timeout is reached.
    ///   Index out parameter is set to the index of the TMultiWaitEvent in the provided array which was signaled.
    ///   More than one event may be signaled; Index only indicates which one caused the function to return. Index is undefined if
    ///   Timeout was reached.
    /// </summary>
    class function WaitForAny(const Events: array of TMultiWaitEvent; out Index: Integer; Timeout: Cardinal = INFINITE): TWaitResult; overload; static;
    /// <summary>Wait until at least one of the indicated TMultiWaitEvents are signaled or Timeout is reached.
    ///    Returns the TMultiWaitEvent instance which was signaled and caused the function to return. Event is
    ///    undefined if Timeout is reached.
    /// </summary>
    class function WaitForAny(const Events: array of TMultiWaitEvent; out Event: TMultiWaitEvent; Timeout: Cardinal = INFINITE): TWaitResult; overload; static;
  end;
Warum macht man die? Damit Du in der IDE sofort die Infos hast.

Oder Schau die Spring4D an... Da ist fast jede Methode beschrieben...

p80286 11. Dez 2015 16:37

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Wer lesen kann ist klar im Vorteil:oops:
Trotzdem bleibt die Frage wer liest's. Besteht die Gefahr, daß Amerikaner oder Franzosen sich daran erfreuen, ist eine deutsche Dokumentation/ deutscher Kommentar nicht sooo toll. Hast Du eine Werkzeugsammlung für den deutschen Markt erstellt, geht Englisch bestimmt, aber der eine oder andere Kunde wird Deutsch dann schon goutieren.
Du hast bestimmt auch schon mal russische Software in die Finger bekommen, mit den Kommentaren/der Dokumentation konnte ich herzlich wenig anfangen .

Gruß
K-H

Der schöne Günther 11. Dez 2015 16:57

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Zitat:

Zitat von Mavarik (Beitrag 1324108)
Hierbei geht es nicht darum eigene Projekte zu dokumentieren, sondern um eine Sourcecode-Sammlung die andere Developer.

Ist es nötig? Wie haltet Ihr das...?

Nix verstehen. Du bekommst Code von einem anderen Team das ihn später wieder zurück bekommt? Ich verstehe das Szenario nicht :|

Mavarik 11. Dez 2015 17:23

AW: Mehrsprachige Quellcode Documentation - Ob & Wie?
 
Zitat:

Zitat von Der schöne Günther (Beitrag 1324141)
Zitat:

Zitat von Mavarik (Beitrag 1324108)
Hierbei geht es nicht darum eigene Projekte zu dokumentieren, sondern um eine Sourcecode-Sammlung die für andere Developer.

Nix verstehen. Du bekommst Code von einem anderen Team das ihn später wieder zurück bekommt? Ich verstehe das Szenario nicht :|

für...

Sorry "Schreibfehler".

Wenn ich/wir ein SDK raus gebe... oder genauer FDK... stellt sich mir die Frage ob es nötig ist eine deutsche Übersetzung an zu bieten...

Mavarik


Alle Zeitangaben in WEZ +1. Es ist jetzt 06:10 Uhr.
Seite 1 von 3  1 23      

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz