metadata: Make JACK_METADATA_* constant

to ensure that it is not modified by any client.

const have internal linkage unless marked by extern

Change-Id: Ife1def2feb43aead32164f479e39ee3fd71b2ba0
Signed-off-by: Adam Miartus <external.Adam.Miartus@de.bosch.com>
Signed-off-by: Timo Wischer <twischer@de.adit-jv.com>
This commit is contained in:
Timo Wischer 2020-05-12 13:20:54 +02:00 committed by Filipe Coelho
parent ba28ffa3db
commit f3e8a6bc6b
3 changed files with 22 additions and 22 deletions

View File

@ -34,8 +34,8 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#include "JackChannel.h"
#include "JackError.h"
extern const char* JACK_METADATA_HARDWARE;
extern const char* JACK_METADATA_PRETTY_NAME;
extern const char JACK_METADATA_HARDWARE[];
extern const char JACK_METADATA_PRETTY_NAME[];
namespace Jack
{

View File

@ -28,16 +28,16 @@
#define JACK_METADATA_PREFIX "http://jackaudio.org/metadata/"
LIB_EXPORT const char* JACK_METADATA_CONNECTED = JACK_METADATA_PREFIX "connected";
LIB_EXPORT const char* JACK_METADATA_EVENT_TYPES = JACK_METADATA_PREFIX "event-types";
LIB_EXPORT const char* JACK_METADATA_HARDWARE = JACK_METADATA_PREFIX "hardware";
LIB_EXPORT const char* JACK_METADATA_ICON_LARGE = JACK_METADATA_PREFIX "icon-large";
LIB_EXPORT const char* JACK_METADATA_ICON_NAME = JACK_METADATA_PREFIX "icon-name";
LIB_EXPORT const char* JACK_METADATA_ICON_SMALL = JACK_METADATA_PREFIX "icon-small";
LIB_EXPORT const char* JACK_METADATA_ORDER = JACK_METADATA_PREFIX "order";
LIB_EXPORT const char* JACK_METADATA_PORT_GROUP = JACK_METADATA_PREFIX "port-group";
LIB_EXPORT const char* JACK_METADATA_PRETTY_NAME = JACK_METADATA_PREFIX "pretty-name";
LIB_EXPORT const char* JACK_METADATA_SIGNAL_TYPE = JACK_METADATA_PREFIX "signal-type";
LIB_EXPORT extern const char JACK_METADATA_CONNECTED[] = JACK_METADATA_PREFIX "connected";
LIB_EXPORT extern const char JACK_METADATA_EVENT_TYPES[] = JACK_METADATA_PREFIX "event-types";
LIB_EXPORT extern const char JACK_METADATA_HARDWARE[] = JACK_METADATA_PREFIX "hardware";
LIB_EXPORT extern const char JACK_METADATA_ICON_LARGE[] = JACK_METADATA_PREFIX "icon-large";
LIB_EXPORT extern const char JACK_METADATA_ICON_NAME[] = JACK_METADATA_PREFIX "icon-name";
LIB_EXPORT extern const char JACK_METADATA_ICON_SMALL[] = JACK_METADATA_PREFIX "icon-small";
LIB_EXPORT extern const char JACK_METADATA_ORDER[] = JACK_METADATA_PREFIX "order";
LIB_EXPORT extern const char JACK_METADATA_PORT_GROUP[] = JACK_METADATA_PREFIX "port-group";
LIB_EXPORT extern const char JACK_METADATA_PRETTY_NAME[] = JACK_METADATA_PREFIX "pretty-name";
LIB_EXPORT extern const char JACK_METADATA_SIGNAL_TYPE[] = JACK_METADATA_PREFIX "signal-type";
#undef JACK_METADATA_PREFIX
namespace Jack

View File

@ -229,7 +229,7 @@ int jack_set_property_change_callback (jack_client_t* client,
* A value that identifies what the hardware port is connected to (an external
* device of some kind). Possible values might be "E-Piano" or "Master 2 Track".
*/
extern const char* JACK_METADATA_CONNECTED;
extern const char JACK_METADATA_CONNECTED[];
/**
* The supported event types of an event port.
@ -242,21 +242,21 @@ extern const char* JACK_METADATA_CONNECTED;
* status byte will gracefully ignore OSC messages if the user makes an
* inappropriate connection.
*/
extern const char* JACK_METADATA_EVENT_TYPES;
extern const char JACK_METADATA_EVENT_TYPES[];
/**
* A value that should be shown when attempting to identify the
* specific hardware outputs of a client. Typical values might be
* "ADAT1", "S/PDIF L" or "MADI 43".
*/
extern const char* JACK_METADATA_HARDWARE;
extern const char JACK_METADATA_HARDWARE[];
/**
* A value with a MIME type of "image/png;base64" that is an encoding of an
* NxN (with 32 < N <= 128) image to be used when displaying a visual
* representation of that client or port.
*/
extern const char* JACK_METADATA_ICON_LARGE;
extern const char JACK_METADATA_ICON_LARGE[];
/**
* The name of the icon for the subject (typically client).
@ -267,14 +267,14 @@ extern const char* JACK_METADATA_ICON_LARGE;
* Theme Specification:
* https://specifications.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html
*/
extern const char* JACK_METADATA_ICON_NAME;
extern const char JACK_METADATA_ICON_NAME[];
/**
* A value with a MIME type of "image/png;base64" that is an encoding of an
* NxN (with N <=32) image to be used when displaying a visual representation
* of that client or port.
*/
extern const char* JACK_METADATA_ICON_SMALL;
extern const char JACK_METADATA_ICON_SMALL[];
/**
* Order for a port.
@ -287,18 +287,18 @@ extern const char* JACK_METADATA_ICON_SMALL;
*
* It is encouraged to use http://www.w3.org/2001/XMLSchema#int as the type.
*/
extern const char* JACK_METADATA_ORDER;
extern const char JACK_METADATA_ORDER[];
/**
* A value that should be shown to the user when displaying a port to the user,
* unless the user has explicitly overridden that a request to show the port
* name, or some other key value.
*/
extern const char* JACK_METADATA_PRETTY_NAME;
extern const char JACK_METADATA_PRETTY_NAME[];
/**
*/
extern const char* JACK_METADATA_PORT_GROUP;
extern const char JACK_METADATA_PORT_GROUP[];
/**
* The type of an audio signal.
@ -309,7 +309,7 @@ extern const char* JACK_METADATA_PORT_GROUP;
* their output directly to speakers. In particular, CV ports are not
* necessarily periodic at all and may have very high DC.
*/
extern const char* JACK_METADATA_SIGNAL_TYPE;
extern const char JACK_METADATA_SIGNAL_TYPE[];
/**
* @}