f*****c 发帖数: 22 | 1 I think it is up to the vendor to choose TCP or UDP as the implementation
of IIOP as long as CORBA do not specify it(I do not know such specification).
Of couse, even if you arre using UDP, you still have to come up with a
protocol to ensure that your packet will be correctly received at the other
end.
So it is also true about one-way function.
As for the pooling mode, it SHOULD be adjustable for individual CORBA products
I once used Visibroker and it can be specified via a method of boa. |
|
b*g 发帖数: 644 | 2 You can specify an expiration date, using the
setMaxTime(int) method of
javax.servlet.http.Cookie. Specifying a expiration time of
zero will void
the cookie, and delete it from the browser.
// Expire the cookie immediately
cookie.setMaxTime( 0 );
// Send cookie back to the browser to void it
response.addCookie(cookie); |
|
m*****e 发帖数: 126 | 3 Copied from Java API Document:
public Object[] toArray()
Returns an array containing all of the elements in this Vector in the
correct order.
public Object[] toArray(Object[] a)
Returns an array containing all of the elements in this Vector in the
correct order. The runtime type of the returned array is that of the
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
specified array. If the Vector fits in the specified array, it is returned
^^^^^^^^^^^^^^^ !!!!!!!!!!!!
therein. |
|
F****n 发帖数: 3271 | 4 Depends on what kind of projects you have. By default, you are using Eclipse
's IDE's project definition, and in that case you can specify the build path
of B to depend on A. You also need to export all dependencies jars used in
A. If it's a plug-in project, then things can get quite complicated.
Basically you should convert A into a plugin project and specify it into B's
plug-in definition. |
|
|
i****e 发帖数: 913 | 6 另外这是有关unchecked/checked exception的讨论
http://www.javapractices.com/topic/TopicAction.do?Id=129
unchecked ex = unrecoverable, for example NPE, IAE
checked ex = recoverable, representing invalid conditions in areas outside
the immediate control of the program (invalid user input, database problems,
network outages, absent files)
(here, database problem is considered as outside of main program logic)
所以Sun的人认为JDBC是side logic, JDBC layer出问题了, main Java program是
recoverable的, 所以就把JDBC搞成checked excepti... 阅读全帖 |
|
i****e 发帖数: 913 | 7 RuntimeException是Exception的subclass, 可以catch,可以rethrow, 也可以
specify/declare在method的delaration上(注意楼主在这里有点概念不清, throws
exception不是signature的一部分, 只是告诉compiler如果是checked exception,
compile时候帮忙check一下; 还有就是subclass的overiding method只能throws同样或
inherited checked exceptions).
Spring JDBC/TopLink/JDO/H8既然跟JDBC反着干, 理应specify all their unchecked
exceptions on method declaration, 其实Spring JDBCTemplate也是这样做了.
http://static.springsource.org/spring/docs/2.0.x/api/org/spring
而且由于是throws RuntimeException, 不catch... 阅读全帖 |
|
E*V 发帖数: 17544 | 8 -P, --no-dereference
never follow symbolic links in SOURCE
-p same as --preserve=mode,ownership,timestamps
--preserve[=ATTR_LIST]
preserve the specified attributes (default: mode,ownership,
timestamps), if possible additional attributes:
context, links, xattr, all
--no-preserve=ATTR_LIST
don't preserve the specified attributes |
|
D**a 发帖数: 757 | 9 我的NAS突然之间就当机了, 好像是ROM或者FIRMWARE出了问题,HDD读不出了。 NAS是
个LINUX BASED的盒子,我把硬盘去了出来, 接到了我的VM上,现在是如下情况, 请
问该如何处理? HDD上是所有的照片和文档, 不能格式化。是下面那个1T的盘。
To run a command as administrator (user "root"), use "sudo ".
See "man sudo_root" for details.
lbblmm@lbblmm-VirtualBox:~$ xfs_repair
Usage: xfs_repair [options] device
Options:
-f The device is a file
-L Force log zeroing. Do this as a last resort.
-l logdev Specifies the device where the external log resides.
-m maxmem ... 阅读全帖 |
|
p****u 发帖数: 2422 | 10 from man page of less
-xn,... or --tabs=n,...
Sets tab stops. If only one n is specified, tab stops are set
at multiples of n. If multiple values separated by commas are
specified, tab stops are set at those positions, and then con‐
tinue with the same spacing as the last two. For example,
-x9,17 will set tabs at positions 9, 17, 25, 33, etc. The
default for n is 8. |
|
p****u 发帖数: 2422 | 11 from Advanced Bash-Scripting Guide:
http://www.tldp.org/LDP/abs/html/io-redirection.html
Chapter 20. I/O Redirection
Table of Contents
20.1. Using exec
20.2. Redirecting Code Blocks
20.3. Applications
There are always three default files [1] open, stdin (the keyboard), stdout
(the screen), and stderr (error messages output to the screen). These, and a
ny other open files, can be redirected. Redirection simply means capturing o
utput from a file, command, program, script, or even code block withi... 阅读全帖 |
|
s****i 发帖数: 2993 | 12 the best method is dynamically creating PDF rather than JPEG.
you guarantee to get same result across browsers and platforms.
or you could try using CSS, specify media as print, and sends
different versions of JPEG, one for view, one for print. but
I haven't tested whether the print version is printed at 300
dpi or about 72. I think you can specify resolution, but no
idea the support of browsers.
the
it |
|
L*********r 发帖数: 92 | 13 After you install SQL 2005, you have at least 2 options:
1.specify the SQL server default data and log path
2.specify the database data and log path when creating individual database |
|
F*******n 发帖数: 89 | 14 I wrote a program with input arguments( argv, argc).
How can I specify these parameters when I execute my program(I simply click
"start" to run, no way to specify the parameters)?
There must be some way to do it.
thanks. |
|
t****t 发帖数: 6806 | 15 7.1.1
3 A register specifier has the same semantics as an auto specifier
together with a hint to the implementation that the object so declared
will be heavily used. [Note: the hint can be ignored and in most
implementations it will be ignored if the address of the object is
taken. --end note] |
|
k**f 发帖数: 372 | 16
Only user defined class can have overloaded operator. The compiler will try
to resolve the operator based on the type of the operand. If you have two
classes of the same name but in different namespace, then you need to
specify which class the object is when it is declared. I don't see how you
can overload an operator with the same signature unless you do it on purpose.
Also related is the special "Koenig lookup".
http://en.wikipedia.org/wiki/Argument_dependent_name_lookup
If you have a specifi |
|
|
c*****t 发帖数: 1879 | 18 Nope. If both patterns match the same string, the rule specified
earlier has the precedence.
Typically, the patterns specified later can be less stringent, because
they only cover strings "leaked" by earlier patterns.
However, in your case, the two patterns are simply different.
p.s [[0-9]] isn't a valid character set I think. [[:digit:]] is.
[a-Z] is dangerous since no one remembers the whole ascii map, unless
you meant [A-Za-z]. |
|
y******e 发帖数: 359 | 19
If you don't specify the absolute path for the dll.
The sequence to find the dll:
1. The directory where the exe is located.
2. The current directory set by SetCurrentDirectory API. (Many other
programs could change the "current directory".
3. %windir%
4. %windir%\system32
5. the folders in the environment variale %PATH%
You could specify the absolute path to the dll then you can be sure the
right dll is loaded. |
|
S*********g 发帖数: 5298 | 20 我把相关的那段贴上来吧
For example, Item 34 describes how a Protocol class exists only to specify
an interface for derived classes; it has no data members, no constructors, a
virtual destructor (see Item 14), and a set of pure virtual functions that
specify the interface. A Protocol Person class might look like this:
class Person {
public:
virtual ~Person();
virtual string name() const = 0;
virtual string birthDate() const = 0;
virtual string address() const = 0;
virtual string nationality() cons |
|
a****l 发帖数: 8211 | 21 Based on what you said, I assume the perl program is in the different folder
from the exec file folder. Then, apparently, I believe when calling the
exec file, you need to specify the path to the exec file in perl script (
otherwise how can the perl script find the exec file?). So, you should be
able to add one more argument to the exec file , which specifies the exec
file location. And , if that argument does not exist, just use the system
default path within exec program.
E.g., you may call |
|
t****t 发帖数: 6806 | 22 Nonstatic data members of a (non-union) class declared without an
intervening access-specifier are allocated so that later members have
higher addresses within a class object. The order of allocation of
nonstatic data members separated by an access-specifier is unspecified
(_class.access.spec_). Implementation alignment requirements might
cause two adjacent members not to be allocated immediately after each
other; so might requirements for space for managing virtual f |
|
s******n 发帖数: 21 | 23 Elegant or not, that's just personal opinion and there is no point to argue
about that. But I do think c# enum provides some very interesting features
that worth mentioning:
- Strongly typed
- Able to specify the base type, int32 will be used if no base type is
specified
- Build-in functions to convert from values to printable strings and vice
versa. Thrust has explained this in his post
- Able to define enum as a bit field.
- Since enum is a class, it can be extended.
Looks like C++ is trying |
|
s*****g 发帖数: 5159 | 24 You will need the process run at different machines with IPs.
One (not simple) suggestion is to install two virtual machines on your
laptop, and manually assign IPs to the two VMs.
Afterward, starting on one vm, do
mpirun [your configuration file with two IPs specified] program
and see how it works.
I do feel debug on the cluster is a easy way for me - ssh in a terminal
will do most of the jobs. Do NOT submit jobs, just mpirun them from the
file / submission server and specify two nodes. Some cl |
|
v*****r 发帖数: 2325 | 25 yes. without explicity specify "access specifier ", it is
class derived: private base {
}
Although the constructors and destructors of the base class are not
inherited themselves, its default constructor (i.e., its constructor with no
parameters) and its destructor are always called when a new object of a
derived class is created or destroyed. |
|
d****p 发帖数: 685 | 26 Finally found this :-)
11.2 If a class is declared to be a base class (clause 10) for another class
using the public access specifier, the public
members of the base class are accessible as public members of the derived
class and protected members of the base
class are accessible as protected members of the derived class. If a class
is declared to be a base class for another
class using the protected access specifier, the public and protected members
of the base class are accessible as
protected |
|
X****r 发帖数: 3557 | 27 9.4.2 Static data members
2 The declaration of a static data member in its class
definition is not a definition and may be of an incomplete
type other than cv-qualified void. A definition shall be
provided for the static data member if it is used in the
program.
...
4 If a static data member is of const integral or const
enumeration type, its declaration in the class definition
can specify a constant-initializer which shall be an
integral constant expression. In that case, the m... 阅读全帖 |
|
e****d 发帖数: 895 | 28 use the /LIBPATH option to specify your library path or you
can specify it in your vs ide project properties.
gd
But |
|
t****t 发帖数: 6806 | 29 3.5 [Program and Linkage]
10 After all adjustments of types (during which typedefs (7.1.3) are
replaced by their definitions), the types specified by all declarations
referring to a given object or function shall be identical, except that
declarations for an array object can specify array types that differ by the
presence or absence of a major array bound (8.3.4). A violation of this rule
on type identity does not require a diagnostic. |
|
t****t 发帖数: 6806 | 30 no no no, usually if g++ and VC has different result, VC is wrong.
according to standard 8.5 clause 9,
9 If no initializer is specified for an object, and the object is of (
possibly cv-qualified) non-POD class type (or array thereof), the object
shall be default-initialized; if the object is of const-qualified type, the
underlying class type shall have a user-declared default constructor.
Otherwise, if no initializer is specified for a nonstatic object, the object
and its subobjects, if any, ... 阅读全帖 |
|
c**********e 发帖数: 2007 | 31 【 以下文字转载自 JobHunting 讨论区 】
发信人: careerchange (Stupid), 信区: JobHunting
标 题: C++ Q90 - Q92
发信站: BBS 未名空间站 (Fri Oct 14 23:32:13 2011, 美东)
C++ Q90: class templates
What type of class template can be nested?
A. Only non-template classes
B. Only class templates
C. Both class templates and non-template classes
D. Neither class templates nor non-template classes
C++ Q91: this pointer
Which one of the following operations requires explicit use of a this
pointer?
A. Calling a member function that require... 阅读全帖 |
|
c**********e 发帖数: 2007 | 32 【 以下文字转载自 JobHunting 讨论区 】
发信人: careerchange (Stupid), 信区: JobHunting
标 题: C++ Q 99-102
发信站: BBS 未名空间站 (Fri Oct 28 23:14:06 2011, 美东)
C++ Q 99: global and static
What type of linkage does global variables and functions preceded by
the storage class specifier static have?
a. Internal
b. Intern
c. External
d. Extern
Answer: a
C++ Q 100: directives
Any number of which of the following directives can appear between
the #if and #endif directives?
a. #elif
b. #endif
c. #else
d. #if
Answer: a
C++ Q101... 阅读全帖 |
|
X****r 发帖数: 3557 | 33 You need something like "struct X;" or "class X;" in forward declaration.
You also need this struct/class keyword along with the struct/class name
(called elaborated type specifier) if you want to specify a type name
shadowed by a function or variable name, e.g.
struct X {
int a;
};
int X() {
return 0;
}
int g = X(); // calls the function
// The 'struct' keyword is required here.
struct X x;
declare
unless |
|
c*******9 发帖数: 6411 | 34 I try to compile multiple c files, and would like the object files ouptut in
the same directory
gcc -c -o /user/ouput -c *.c
but does not seem to work, is there an option in gcc to specify that?
in visual c++, i can use /fo option to specify a folder for ouput, anything
similar in gcc?
thanks |
|
X****r 发帖数: 3557 | 35 这不是C++的语法,而是C的语法。至少C++98里没有。
C++11我不太熟,好像也没有把这个加进去。C99里描述如下:
6.7.5.3 Function declarators (including prototypes)
7 A declaration of a parameter as ‘‘array of type’’
shall be adjusted to ‘‘qualified pointer to type’’,
where the type qualifiers (if any) are those
specified within the [ and ] of the array type
derivation. If the keyword static also appears
within the [ and ] of the array type derivation,
then for each call to the function, the value of
the corresponding actual argumen... 阅读全帖 |
|
nr 发帖数: 67 | 36 C++11 standard 12.6.2 clause 10
10
In a non-delegating constructor, initialization proceeds in the following
order:
— First, and only for the constructor of the most derived class (1.8),
virtual base classes are initialized in
the order they appear on a depth-first left-to-right traversal of the
directed acyclic graph of base classes,
where “left-to-right” is the order of appearance of the base classes in
the derived class base-specifier-list.
— Then, direct base classes are initialized in decla... 阅读全帖 |
|
l*********s 发帖数: 5409 | 37 the standard requires custom ctor for const class, probably thee compiler
has a bug to let you go through with vCB
quote/
8.5]
9. If no initializer is specified for an object, and the object is of
(possibly cv-qualified) non-POD class type (or array thereof), the object
shall be default-initialized; if the object is of const-qualified type,
the underlying class type shall have a user-declared default constructor.
Otherwise, if no initializer is specified for an object, the object and
its subobje... 阅读全帖 |
|
a********l 发帖数: 980 | 38 SA weekend patch reboot之后突然就没法build了...
build 的 console output-
> /usr/bin/git fetch --tags --progress /home/user/repositories/git/user.git
+refs/heads/*:refs/remotes/origin/*
ERROR: Error fetching remote repo 'origin'
hudson.plugins.git.GitException: Failed to fetch from /home/user/
repositories/git/user.git
at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:735)
at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:983)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1016)
... 阅读全帖 |
|
a********l 发帖数: 980 | 39 存在,如果新建free style project, 不specify JDK, 用 gradle的话可以fetch,但
specify JDK后就不能fetch了 |
|
l**********n 发帖数: 8443 | 40 https://github.com/ternjs/acorn
npm install acorn
https://github.com/MatAtBread/acorn-es7-plugin/
var code = "async function x(){ if (x) return await(x-1) ; return 0 ; }\n";
var ast = acorn.parse(code,{
// Specify use of the plugin
plugins:{asyncawait:true},
// Specify the ecmaVersion
ecmaVersion:7
}) ;
// Show the AST
console.log(JSON.stringify(ast,null,2)) ;
output:
{
"type": "Program",
"body": [
{
"type": "FunctionDeclaration",
"id": {
"type": "... 阅读全帖 |
|
x*********g 发帖数: 4 | 41 Hmm, actually I am just playing Diablo 2 when I realize i
need a sniffer to judge item value.
I used spynet, it didn't has any hex searching ability.
I used netxray 3.0.3 or NAI snifferpro 4.5 or whatever you
call it, it does has hex search, but you have to specify an
offset value on every pattern.
My pattern is like "7a 00 00 00", there are 12 locations
that this string may appear, but i think netxray wont accept
80 OR criteria.
So have you heard any sniffer could hex search without
specify loc |
|
T*******n 发帖数: 493 | 42
I usually use something like
set terminal postscript eps enhanced color "Times-Roman" 20
set output "file.eps"
This will result in an EPS file that uses the PS Times-Roman font
at 10 pt as the default font; when the "eps" option is specified,
the specified pt size (20) is divided by 2 to give the actual pt size.
Try one or more of these commands (say "help set ..." to see the
full syntax): set xrange, set yrange, set size, set xtics, set ytics,
set mxtics, set mytics |
|
p*****m 发帖数: 31 | 43 maybe during linking, you havn't setting the libraries for X11.
the right format shoult be:
cc this.c -o this -lx11 -L/usr/X/lib/x11
use -l to specify the library name
-L to specify the path for library
在 coolman (snail) 的大作中提到: 】 |
|
s**i 发帖数: 30 | 44 a sample code:
#! /bin/sh
# $Id: ftpget,v 1.2 91/05/07 21:15:43 moraes Exp $
# Script to perform batch anonymous ftp. Essentially converts a list of
# of command line arguments into input to ftp.
# Simple, and quick - written as a companion to ftplist
# -h specifies the remote host (default prep.ai.mit.edu)
# -d specifies the remote directory to cd to - you can provide a sequence
# of -d options - they will be cd'ed to in turn. If the paths are relative,
# make sure you get the sequence right. B |
|
f****n 发帖数: 4615 | 45 Adding more space to swap space, first mkfile a big file, then "swap -a"
this file to swap file. This mkfile command has two arguments: -n and -v.
"-v" specifies verbose reporting mode. "-n" indicates that the disk space
should be allocated as needed up to the specified size( instead of all
being allocated when the file is created). I don't know the meaning
in parentheses. Can you help me? |
|