One time definition of a generic base class with recursive type specifier. Each node has one parent and multiple children.
/// <summary>
/// Generic base class for a tree structure
/// </summary>
/// <typeparam name="T">The node type of the tree</typeparam>
pub...
Open your jenkins instance script console http://yourJenkins:port/script
following is an example for how to get information about this instance. copy the code to the console and click "Run".
/* This scripts shows how to get basic information about Jenkins instance */
def jenkins = Jenki...
The vertical layout set up the object inside it vertically.
#include "mainwindow.h"
#include <QApplication>
#include <QMainWindow>
#include <QWidget>
#include <QVBoxLayout>
#include <QPushButton>
int main(int argc, char *argv[])
{
QApplication...
You can combine mulple layout thanks to other QWidgets in your main layout to do more specifics effects like an information field: for example:
#include <QApplication>
#include <QMainWindow>
#include <QWidget>
#include <QVBoxLayout>
#include <QPushButton>
#inclu...
To set up a simple hibernate project using XML for the configurations you need 3 files, hibernate.cfg.xml, a POJO for each entity, and a EntityName.hbm.xml for each entity. Here is an example of each using MySQL:
hibernate.cfg.xml
<?xml version="1.0" encoding="utf-8"?>
&...
QtCreator is, at the moment, the best tool to create a Qt application. In this example, we will see how to create a simple Qt application which manage a button and write text.
To create a new application click on File->New File or Project:
Then choose the Projects->Application->Qt Widge...
As this is an audio, we don't need a QVideoWidget. So we can do:
_player = new QMediaPlayer(this);
QUrl file = QUrl::fromLocalFile(QFileDialog::getOpenFileName(this, tr("Open Music"), "", tr("")));
if (file.url() == "")
return ;
_player->setMedia(f...
With the help of West Wind's wwDotNetBridge, you can easily have access .NET code within a VFP program.
The white paper has all the details, but this concise example will help illustrate the basic steps to running a method in a .NET assembly.
Note that wwDotNetBridge can directly access simple pro...
Datapump jobs can be monitored using
1. data dictionary views:
select * from dba_datapump_jobs;
SELECT * FROM DBA_DATAPUMP_SESSIONS;
select username,opname,target_desc,sofar,totalwork,message from V$SESSION_LONGOPS where username = 'bkpadmin';
2. Datapump status:
Note down the j...
Go will throw an error when there is a variable that is unused, in order to encourage you to write better code. However, there are some situations when you really don't need to use a value stored in a variable. In those cases, you use a "blank identifier" _ to assign and discard the assign...
There are some situations where you won't be sure what type a variable is when it is returned from a function. You can always check a variable's type by using var.(type) if you are unsure what type it is:
x := someFunction() // Some value of an unknown type is stored in x now
switch x := x.(type...
/* these IN and OUT filerefs can point to anything */
filename in "anyfilehere.xlsx";
filename out "anyfilehere.xlsx";
/* copy the file byte-for-byte */
data _null_;
length filein 8 fileid 8;
filein = fopen('in','I',1,'B');
fileid = fopen('out','O',1,'B');
...
First, I will place my date into a Macro Variable.
NOTE: I find that
date9. works great with IBM® Netezza® SQL and Transact-SQL. Use whichever format that works for the type of SQL you're executing.
data _null_;
call symput('testDate',COMPRESS(put(today(),date9.)));
;RUN;
%PUT ...
Filename myEmail EMAIL
Subject = "My Email Subject"
From = "[email protected]"
To = '[email protected]'
CC = '[email protected]'
Type = 'Text/Plain';
Data _null_; File myEmail;
PUT "Email content";
PUT &q...