1    /* --COPYRIGHT--,ESD
     2     *  Copyright (c) 2008 Texas Instruments. All rights reserved. 
     3     *  This program and the accompanying materials are made available under the 
     4     *  terms of the Eclipse Public License v1.0 and Eclipse Distribution License
     5     *  v. 1.0 which accompanies this distribution. The Eclipse Public License is
     6     *  available at http://www.eclipse.org/legal/epl-v10.html and the Eclipse
     7     *  Distribution License is available at 
     8     *  http://www.eclipse.org/org/documents/edl-v10.php.
     9     *
    10     *  Contributors:
    11     *      Texas Instruments - initial implementation
    12     * --/COPYRIGHT--*/
    13    /*
    14     *  ======== LoggerUart.xdc ========
    15     */
    16    
    17    /*!
    18     *  ======== LoggerUart ========
    19     *  A logger that writes events to a UART
    20     *
    21     *  @a(Examples)
    22     *  Configuration example: The following XDC configuration statements
    23     *  create a logger instance, assign it as the default logger for all
    24     *  modules, and enable `USER1` logging in all modules of the package
    25     *  `my.pkg`. See the `{@link Diags#setMaskMeta Diags.setMaskMeta()}` function
    26     *  for details on specifying the module names.
    27     *
    28     *  @p(code)
    29     *  var Defaults = xdc.useModule('xdc.runtime.Defaults');
    30     *  var Diags = xdc.useModule('xdc.runtime.Diags');
    31     *  var LoggerUart = xdc.useModule('xdc.runtime.LoggerUart');
    32     *
    33     *  var LoggerUartParams = new LoggerUart.Params();
    34     *  Defaults.common$.logger = LoggerUart.create(LoggerUartParams);
    35     *  Diags.setMaskMeta("my.pkg.%", Diags.USER1, Diags.RUNTIME_ON);
    36     *  @p
    37     */
    38    
    39    module LoggerUart inherits xdc.runtime.ILogger {
    40    
    41        /*!
    42         *  ======== ITimestampProxy ========
    43         *  User supplied time-stamp proxy
    44         *
    45         *  This proxy allows `LoggerUart` to use a timestamp server different
    46         *  from the server used by `{@link xdc.runtime.Timestamp}`. However, if
    47         *  not supplied by a user, this proxy defaults to whichever timestamp
    48         *  server is used by `Timestamp`.
    49         */
    50        proxy TimestampProxy inherits xdc.runtime.ITimestampClient;
    51    
    52    instance:
    53    
    54        /*!
    55         *  ======== create ========
    56         *  Create a `LoggerUart` logger
    57         *     
    58         *  The logger instance will route all log events it receives to
    59         *  the {@link System#printf} function.
    60         */
    61        create();
    62     
    63    internal:
    64        
    65        struct Instance_State {
    66            Bool enabled;
    67        };
    68    }