BoxLayout and Container.validate()
I noticed that if a BoxLayout (or any other layout) is set for a Container, its explicit sizes (maximum and minimum) are ignored after validate() is called on that Container, meaning that the object is resized to values other than what it was configured with.
Am I missing something? How do I prevent that from happening?
thank you
mike
That matches our experience witth Box/BoxLayout.
GridBagLayout has not such problem.
Similar Messages
-
HT204268; I have purchases on an aol login pre 2008 and all recent stuff under an apple id. I currently see and use everything when i login with the apple id. After March 31st will my apple id account still show and contain all?
I understand the instructions to create a new account id (apple id) from the old aol account. However, does this mean my purchases will be split into 2 accounts; or does the fact that I currently see everything under my apple id (regardless of the purchased by username) mean this will all still appear in my current account as it does now?You see them where when you login your non-AOL account ?
If you currently have two accounts (the AOL username account and an email address account) then you will continue to have two accounts, and nothing should change when you update the AOL account to be an email address (apart from how you access that account).
You will just be renaming the account to have an email address for accessing it, not creating a new account. -
ResultList and Container objects
The Java ResultList and Container objects are used in SAP Mapping UDF's ...does anyone know which specific jar files contain these object definitions ?
Thanks,
Rod.For PI 7.0(3.0) you need the libraries: aii_mt_rt.jar, aii_map_api.jar, aii_utilxi_misc.jar
For PI 7.1 you need the libraries: com.sap.xi.mapping.tool.lib_api.jar, com.sap.xpi.ib.mapping.lib.jar, com.sap.aii.utilxi.server.jar
/people/stefan.grube/blog/2005/12/30/test-user-defined-functions-for-the-xi-graphical-mapping-tool-in-developer-studio -
Trying to understand context indexes and contains-help
Hi
i am using
Achieving functionality of many preferences using one context index
to understand context indexes and contains
and i get the following
Error starting at line 1 in command:
begin
ctx_ddl.create_preference ('nd_mcds', 'multi_column_datastore');
ctx_ddl.set_attribute ('nd_mcds', 'columns', 'text nd, text text');
ctx_ddl.create_section_group ('nd_sg', 'basic_section_group');
ctx_ddl.add_ndata_section ('nd_sg', 'nd', 'nd');
ctx_ddl.create_preference ('test_lex', 'basic_lexer');
ctx_ddl.set_attribute ('test_lex', 'whitespace', '/\|-_+');
end;
Error report:
ORA-06550: line 5, column 15:
PLS-00302: component 'ADD_NDATA_SECTION' must be declared
ORA-06550: line 5, column 7:
PL/SQL: Statement ignored
06550. 00000 - "line %s, column %s:\n%s"
*Cause: Usually a PL/SQL compilation error.
*Action:
so i am using the following to check for the error
http://docs.oracle.com/cd/E18283_01/text.112/e16593/cddlpkg.htm#BABCBFCB
plus
oracle text application developer's guide
plus
oracle text reference
but these have not listed that error (i have even googled this in vain)
background::we were actually using catsearch but because of its downsides i want to implement this
Is Achieving functionality of many preferences using one context index a good place to start when one does not know about
context and contains??
please post any other useful link for contains and context index that even explains
1) fuzzy
2) stem
3) synonym
4) near
5) soundex
6)ndata
7)lexer
thanks in advanceNdata is new to Oracle 11g. Your other posts indicate that you are using Oracle 10g, so you don't have ndata, so you get an error when you try to use it. If you want to use the 11g features that enable context indexes with contains to do all of the things that ctxcat indexes with catsearch do, then you need to upgrade to 11g.
The online documentation is searchable. Most things regarding Oracle Text are contained in either the Oracle Text Reference or the Oracle Text Application Developer's guide.
I suggest that you start with something very simple, then build from there.
The following is similar to your other post that used catsearch:
SCOTT@orcl_11gR2> CREATE TABLE mv_cat_seg_reg_prod
2 (cat_ids VARCHAR2 ( 7),
3 act_status VARCHAR2 (10),
4 name VARCHAR2 ( 1),
5 email VARCHAR2 ( 1),
6 address1 VARCHAR2 ( 1),
7 address2 VARCHAR2 ( 1),
8 contact_name VARCHAR2 ( 1),
9 mobile VARCHAR2 ( 1),
10 telephone VARCHAR2 ( 1))
11 /
Table created.
SCOTT@orcl_11gR2> INSERT ALL
2 INTO mv_cat_seg_reg_prod VALUES
3 ('1', 'Y', 'A', 'B', 'C', 'D', 'E', 'F', 'G')
4 INTO mv_cat_seg_reg_prod VALUES
5 ('2', 'N', 'H', 'I', 'J', 'K', 'L', 'M', 'N')
6 SELECT * FROM DUAL
7 /
2 rows created.
SCOTT@orcl_11gR2> CREATE INDEX mv_cat_seg_reg_prod_idx
2 ON mv_cat_seg_reg_prod (cat_ids)
3 INDEXTYPE IS CTXSYS.CONTEXT
4 /
Index created.
SCOTT@orcl_11gR2> SELECT token_text FROM dr$mv_cat_seg_reg_prod_idx$i
2 /
TOKEN_TEXT
1
2
2 rows selected.
SCOTT@orcl_11gR2> SELECT *
2 FROM (SELECT SCORE (1), name, email, address1, address2, contact_name, mobile, telephone
3 FROM mv_cat_seg_reg_prod
4 WHERE CONTAINS (cat_ids, '1', 1) > 0
5 AND act_status = 'Y'
6 ORDER BY DBMS_RANDOM.VALUE)
7 WHERE ROWNUM < 8
8 /
SCORE(1) N E A A C M T
4 A B C D E F G
1 row selected. -
HashSet get() and contains() methods, by value or reference?
All the tutorials I've seen on HashSets use Strings as the object type. With Strings, it seems the get() and contains() methods work by value, not by reference.
<CODE>
String s1 = "dog";
String s2 = "cat";
String s3 = "dog";
HashSet<String> set = new HashSet<String>();
set.add(s1);
System.out.println(set.contains(s1)); //true;
System.out.println(set.contains(s2)); //false
System.out.println(set.contains(s3)); //true
</CODE>
But when I use a custom object, it works by reference:
<CODE>
MyClass c1 = new MyClass("dog", 1);
MyClass c2 = new MyClass("cat", 1);
MyClass c3 = new MyClass("dog", 2);
MyClass c4 = new MyClass("dog", 1);
HashSet<MyClass> myClassSet = new HashSet<MyClass>();
myClassSet.add(c1);
System.out.println(myClassSet.contains(c1)); //true
System.out.println(myClassSet.contains(c2)); //false
System.out.println(myClassSet.contains(c3)); //false
System.out.println(myClassSet.contains(c4)); //false
</CODE>
("MyClass" is a simple class that holds a String and an int).
Is there any way I can get the set to select by value rather than reference for objects that aren't String?
If so, is it possible that the value test could be customised, so that, for example, the above will return true if the String in MyClass is the same, regardless of the int value?803559 wrote:
With Strings, it seems the get() and contains() methods work by value, not by reference.
String s1 = "dog";
String s2 = "cat";
String s3 = "dog";
System.out.println(set.contains(s1)); //true;
System.out.println(set.contains(s2)); //false
System.out.println(set.contains(s3)); //true
Is there any way I can get the set to select by value rather than reference for objects that aren't String?Warning: Never use the term "by reference" around Java geeks. It makes 'em go all green at the gills and they start muttering about 'bloody C++ crossovers'.
However, as DrClap pointed out, you've mis-diagnosed the problem:
System.out.println(s1 == s1);
System.out.println(s1 == s2);
System.out.println(s1 == s3));would print out the exact same results.
For an explanation why, Google "Java String pool" or try [url http://stackoverflow.com/questions/3297867/difference-between-string-object-and-string-literal]here.
If so, is it possible that the value test could be customised, so that, for example, the above will return true if the String in MyClass is the same, regardless of the int value?Absolutely. But, as others have said, you'd need to override equals() and hashCode().
Winston -
Using databases and container events?
I'm having trouble finding documents show how one should use databases and listen for container events? I'm using Berkley Java DB. I'll need all my remote object to have access to the database. How do I pass that in? Custom adapters? Also, when Tomcat shuts down I need to close the database, how would this be down? Custom adapters? So I may be answering my own question, but I'm asking cause I really don't see anything in the documentation that points this out. It really looks like I'd be using singletons and factories for this. I could register a Servlet or Servlet Context to listen for Tomcat events, but I figured it couldn't hurt to ask others using Blaze, as I'm very new to it. Thanks.
So how would you tell Blaze to use this? Is there something you put into the config file? My thoughts on all this is to use PicoContainer to manage all services then create an adapter to inject all resources when creating remote objects. But this seems a little heavy if Blaze can do all this for me. The adapter seems like the injection point to me. Is that not what it's used for? Or is using it like that bad practice under Blaze? I've read all I can find on Blaze, so either it's missing docs, or I'm not finding them all. If I'm missing them, by all means let me know where to go. I don't want to ask questions that are already answered in documents else where.
On Tue, May 20, 2008 at 10:51 AM, Mete Atamel <
[email protected]> wrote:
A new message was posted by Mete Atamel in
General Discussion --
Using databases and container events?
I think it's mainly in JavaDocs but here's a sample I have where I check to make sure the HSQLDB is running as the BlazeDS starts up:
import java.sql.Connection;
import java.sql.SQLException;
import flex.messaging.config.ConfigMap;
import flex.messaging.services.AbstractBootstrapService;
public class DatabaseCheckService extends AbstractBootstrapService
// This is called right before server starts up.
public void initialize(String id, ConfigMap properties)
Connection c = null;
try
// Check that the database is running...
c = ConnectionHelper.getConnection();
// ... if yes return
return;
catch (SQLException e)
System.out.println("DB is not running!");
finally
ConnectionHelper.close(c);
// This is called as server is starting.
public void start()
// No-op
// This is called as server is stopping.
public void stop()
// No-op
View/reply at
Using databases and container events?
Replies by email are OK.
Use the
unsubscribe form to cancel your email subscription.
"All that is necessary for the triumph of evil is that good men do nothing." - Edmund Burke -
Hi,
My wife wants me to import a group of contacts she's compiled of invitees to a party we're throwing. The problem is twofold:
1) When I import her list, which contains some contacts I already have in my list, her duplicate contacts overwrite my existing ones, which is not good in cases where I have more detailed contact information for the person than she does. Is there a way to import her group without overwriting the duplicates using her info?
2) There are many contacts in this group that I'll want to delete from my contact list afterward, as my car takes all of my contacts via bluetooth, and I'd rather purge most of this group after the invites are sent. Is there a way to import these individuals and contain them for later deletion without having them added to my main contact list?
Whew! Thanks for reading all of that, and thanks so much in advance for any help you might be able to give!
Cheers,
RobOops... figured this out, with the update options, and then I can just save my address book and restore it to that saved version whenever I want.
-
Tuning SQL query with SDO and Contains?
I'trying to optimize a query
with a sdo_filter and an intermedia_contains
on a 3.000.000 records table,
the query look like this
SELECT COUNT(*) FROM professionnel WHERE mdsys.sdo_filter(professionnel.coor_cart,mdsys.sdo_geometry(2003, null, null,mdsys.sdo_elem_info_array(1,1003,4),mdsys.sdo_ordinate_array(809990,2087279,778784,2087279,794387,2102882)),'querytype=window') = 'TRUE' AND professionnel.code_rubr ='12 3 30' AND CONTAINS(professionnel.Ctx,'PLOMBERIE within Nom and ( RUE within Adresse1 )',1)>0
and it takes 15s on a bi 750 pentium III with
1.5Go of memory running under 8.1.6 linux.
What can i do to improve this query time?
nullHi Vincent,
We have patches for Oracle 8.1.6 Spatial
on NT and Solaris.
These patches include bug fixes and
performance enhancements.
We are in the process of making these patches
avaialble in a permanent place, but until then, I will temporarily put the patches on:
ftp://oracle-ftp.oracle.com/
Log in as anonymous and use your email for
password.
The patches are in /tmp/outgoing in:
NT816-000706.zip - NT patch
libordsdo.tar - Solaris patch
I recommend doing some analysis on
individual pieces of the query.
i.e. time the following:
1)
SELECT COUNT(*)
FROM professionnel
WHERE mdsys.sdo_filter(
professionnel.coor_cart,
mdsys.sdo_geometry(
2003, null, null,
mdsys.sdo_elem_info_array(1,1003,4),
mdsys.sdo_ordinate_array(
809990,2087279,
778784,2087279,
794387,2102882)),
'querytype=window') = 'TRUE';
2)
SELECT COUNT(*)
FROM professionnel
WHERE CONTAINS(professionnel.Ctx,
'PLOMBERIE within Nom and ( RUE within Adresse1)',1) >0;
You might want to try reorganizing the entire
query as follows (no promises).
If you contact me directly, I can try to
help to further tune the SQL.
Hope this helps. Thanks.
Dan
select count(*)
FROM
(SELECT /*+ no_merge */ rowid
FROM professionnel
WHERE mdsys.sdo_filter(
professionnel.coor_cart,
mdsys.sdo_geometry(
2003, null, null,
mdsys.sdo_elem_info_array(1,1003,4),
mdsys.sdo_ordinate_array(809990,2087279,
778784,2087279,
794387,2102882)),
'querytype=window') = 'TRUE'
) a,
(SELECT /*+ no_merge */ rowid
FROM professionnel
WHERE CONTAINS(professionnel.Ctx,
'PLOMBERIE within Nom and
( RUE within Adresse1)',1) >0
) b
where a.rowid = b.rowid
and professionnel.code_rubr ='12 3 30';
**NOTE** Try this with no index on code_rubr
null -
Hi,
I have a little problem with powershell and "contains"
In this situation works well and return "true"
$test = "where is the word"
($test).Contains("word")
but in this other return always "false"
$test = Get-Process
($test).Contains("winlogon")
Why?
Thanks
Andrea Gallazzi
windowserver.it - blog:
andreagx.blogspot.com
This posting is provided AS IS with no warranties, and confers no rights.Hi,
Try looking at the ProcessName property:
PS C:\Scripts\PowerShell Scripts\Misc Testing\1-10-2014> $test = Get-Process
PS C:\Scripts\PowerShell Scripts\Misc Testing\1-10-2014> $test.ProcessName.Contains('winlogon')
True
EDIT: If I remember correctly, I believe this requires PS3+ though.
EDIT2: This will work if you only have v2 (I'm sure there's a better way to do this, but this'll work in a pinch):
PS C:\> $found = $false
PS C:\> $test = Get-Process
PS C:\> $test | ForEach { If ($_.ProcessName.Contains('winlogon')) { $found = $true } }
PS C:\> $found
True
Don't retire TechNet! -
(Don't give up yet - 12,575+ strong and growing) -
I create index:
SQL> CREATE INDEX UM2_ATTRS_STR_I_ctx ON UM2_ENTRIES_ATTRS
(STRING_VALUE) INDEXTYPE IS CTXSYS.CONTEXT;
2
Index created.
I've got 2 query:
SQL> select count(e.id) from um2_entries e , um2_entries_attrs a where e.id = a.entry_id
and a.name = 'user.name'
and a.string_value like '%__%';
2 3
COUNT(E.ID)
1734
94 msec!!!!!!!!
SQL> select count(e.id) from um2_entries e , um2_entries_attrs a where e.id = a.entry_id
and a.name = 'user.name'
and contains(a.string_value, '%__%', 1) > 0;
2 3
COUNT(E.ID)
1734
7 sec!!!!!!!!!!!!!!
Why does one of them (with LIKE) goes much faster than the other?FYI - you might want to check the documentation on when wildcards are needed for CONTAINS vs. LIKE. From your example I can't tell whether you are looking for a part of a term (where a wildcard would be appropriate for CONTAINS), or if you are going to look for a term within a string (no wildcard needed for CONTAINS, but one is required for LIKE).
Example - Assuming a string value of HELLO WORLD
select count(e.id) from um2_entries e , um2_entries_attrs a where e.id = a.entry_id
and a.name = 'user.name'
and a.string_value like 'Hello';
** No record found - case-sensitive and partial string
select count(e.id) from um2_entries e , um2_entries_attrs a where e.id = a.entry_id
and a.name = 'user.name'
and a.string_value like 'HELLO';
** No record found - Partial string
select count(e.id) from um2_entries e , um2_entries_attrs a where e.id = a.entry_id
and a.name = 'user.name'
and a.string_value like 'HELLO%';
** Record found
select count(e.id) from um2_entries e , um2_entries_attrs a where e.id = a.entry_id
and a.name = 'user.name'
and CONTAINS(a.string_value, 'Hello') > 0;
** Record found - Oracle Text is case-insensitive
** by default, so mixed-case here doesn't matter. Also,
** the search is against the DR$ tables where
** HELLO is a token. No need for a wildcard.
I just wanted to make the differences between these two searches at least partially clear. Your earlier comparison seemed to indicate that you expected no difference regardless of search criteria and that just isn't the case. Some of the reasons for using wildcard or string functions are not valid when Oracle Text is used. That's one reason it is very usefull. Add stemming, fuzzy search, or a thesaurus and you go FAR beyond LIKE.
Please do reference the CONTAINS sections in the online docs if you have more questions on these differences. They go far beyond where I just did.
-Ron -
Differnce Between Webservice and Container
I am geting confusion on the difference of Webservice and Container...
Can you please give some function of each that can differentiate both separately?
Is container reside in Webservice ...??Sorry the question is Diff Bet Webserver and Container...
-
I have hp compaq nw9440 mobile workstation the white screen appear and contain an error
i have hp compaq nw9440 mobile workstation the white screen appear and contain an error:
uoy computer has suffered from a non - recoverable system error please call our support line for assistance
713-634-2494sneakypete1 a écrit:
I use Photoshop Elements 12 for my photos. I have a constant problem where my photos don't print like they appear on the screen. They come out darker than the screen shows. If brighten them in the program, I have to almost make the photo appear "white" in order to look good printed. ?????? What can I do to fix this problem??
I am ready to bet that your display is much, much too bright (like all displays at factory settings.
Why Are My Prints Too Dark -
Safari launches a window and contains several tabs
Oh boy, My Safari was perfect for the most part in the last 3 years, that is to say, if I launch Safari to browse the web, the browser would launch with a new window, fresh with default page starting at top sites. And by top sites, I mean the various web sites or pages that i have previously gone to recently most frequently. These pages are presented in miniaturized thumbnails of the whole page, or the top part of the page, and are neatly presented in 4, 8, or 12 slots tabulation for my choosing, or that my keyboard focus would already be on the address bar so I could type any other url as I wish. But until the last 1-2 updates ago I start to notice something strange, when I launch Safari, the browser doesn't go to the usual way as I described above, instead it launches a window and contains several tabs. Of which are places i have been recently, but I wouldn't call those as "top sites" by a long shot. At first I didn't realize what's happening exactly. In fact it seemed to me a bit like when my Safari reopen the tabs from my previous session. It first started with a few tabs, and then a few more each week (actually my main browser is now Chrome sorry to say, but there are several personal reasons that I still use Safari to browse certain web sites, therefore, I may not open and use Safari every day. I think last week was still just 10 tabs or so, now it's 156 tabs... my mac constipates from the sharp drain of memory and it now happens even before the browser window has started rendering. Usually, when my mac is done with beach balling, i immediately right click on the first tab I see, and select "close all other tabs", then command-w to close the last tab. Then I reopen new tab/window (cmd-n) and start my browsing all fresh. A new window launches, but only to dump the 156 tabs all over on me again. clearing web data, cookies, clearing cache, disabling all extensions, nothing seems to work so far. And the Apple Care Support would probably tell me to format the hard disk and reinstall new. I've been down that road too many times already, almost as much as I had to do the same thing when i was using windows. Ugh, even Chrome is far from perfect, that's why i come back to Safari from time to time. And I find my Firefox experience is still clunky, ugh. Have we fallen in to the Dark Ages for web browsers or something?
<Re-Titled By Host>Of which are places i have been recently
Delete the cache ..
Open a Finder window. From the Finder menu bar click Go > Go to Folder
Type or copy paste the following
~/Library/Caches/com.apple.Safari/Cache.db
Click Go then move the Cache.db file to the Trash.
Quit and relaunch Safari to test. -
Difference between panel and container
if both panel and container can contain components inside , then that is the defference between them?
thanks in advanced.if both panel and container can contain components insideJPanel inherits this ability because it extends Container. The point of extending classes is to provide additional functionality. Read the API to see what additional functionality JPanel provides.
The main difference is that JPanel is a Swing component. You should always use Swing components in a Swing application. This will ensure painting of the panel and all its child components are done correctly. -
Difference between Table and Container
Hi,
Whats the difference between table and container.
How to create container in smartform.
Cheers
SenthilHi,
I have a requirement to remove a column from an existing container. I removed a column, but still the column showing up.. so I decided to recreate the container again. But I can create only table. How to make this as container.
Cheers
Senthil
Maybe you are looking for
-
How to propagate changes in RFC to XI....?
Hi Guys, I changed parameter in one of the RFC..the RFC is already being used in XI. I know there is someway to refresh XI with the changes done in RFC, but I am unable to recall.. Can somebody please help in activating my sleeping neurons? Thanking
-
Which pretty much says it all. Unless it is a complete coincidence, upgrading to 9 effectively killed my Apple TV sync ability. Windows XP, never had an issue before with the wireless network (been running ATV for nearly four years now) and I don't h
-
Lost my keychain password and cannot retrieve it from the keychain app.
After restarting my MacBook Pro I reset my computer password now it's asking for the keychain password which I forgot. I've tried everything including sending the keychain app to the trash (which it will not let me).
-
Post form to 3rd party website
I have searched your forums, but not found what I need. I am new to Java, and am battling to put together code to: a) open a URL (e.g. www.google.com) b) post data into a form (e.g. some keywords) c) submit the form Where can I find an example?
-
Macbook Pro trackpad doesn't work on word
My macbook pro mouse trackpad isn't working while I'm on microsoft word. It works on other application like safari but refuses to work on word. It still clicks and i can use the sidebar to move up and down pages but i am unable to slide down the page