Update the webpage (#1820)
* Add docs of extensions * Use `category` to distinct dropdown pages * Sort the documents alphabetical JerryScript-DCO-1.0-Signed-off-by: Zsolt Borbély zsborbely.u-szeged@partner.samsung.com
This commit is contained in:
+1
-27
@@ -1,6 +1,7 @@
|
||||
---
|
||||
layout: page
|
||||
title: Port API
|
||||
category: documents
|
||||
permalink: /port-api/
|
||||
---
|
||||
|
||||
@@ -44,20 +45,6 @@ typedef enum
|
||||
These are the only I/O functions jerry calls.
|
||||
|
||||
```c
|
||||
/**
|
||||
* Print a string to the console. The function should implement a printf-like
|
||||
* interface, where the first argument specifies a format string on how to
|
||||
* stringify the rest of the parameter list.
|
||||
*
|
||||
* This function is only called with strings coming from the executed ECMAScript
|
||||
* wanting to print something as the result of its normal operation.
|
||||
*
|
||||
* It should be the port that decides what a "console" is.
|
||||
*
|
||||
* Example: a libc-based port may implement this with vprintf().
|
||||
*/
|
||||
void jerry_port_console (const char *fmt, ...);
|
||||
|
||||
/**
|
||||
* Jerry log levels. The levels are in severity order
|
||||
* where the most serious levels come first.
|
||||
@@ -142,19 +129,6 @@ void jerry_port_fatal (jerry_fatal_code_t code)
|
||||
#include <stdarg.h>
|
||||
#include "jerryscript-port.h"
|
||||
|
||||
/**
|
||||
* Provide console message implementation for the engine.
|
||||
*/
|
||||
void
|
||||
jerry_port_console (const char *format, /**< format string */
|
||||
...) /**< parameters */
|
||||
{
|
||||
va_list args;
|
||||
va_start (args, format);
|
||||
vfprintf (stdout, format, args);
|
||||
va_end (args);
|
||||
} /* jerry_port_console */
|
||||
|
||||
/**
|
||||
* Provide log message implementation for the engine.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user