Subversion Repository Public Repository

litesoft

Diff Revisions 949 vs 950 for /trunk/Java/GWT/OldClient/src/org/litesoft/GWT/client/IMenuableDef.java

Diff revisions: vs.
  @@ -1,26 +1,26 @@
1 - // This Source Code is in the Public Domain per: http://unlicense.org
2 - package org.litesoft.GWT.client;
3 -
4 - import org.litesoft.commonfoundation.typeutils.*;
5 -
6 - public interface IMenuableDef {
7 - public static final IMenuableDef[] EMPTY_ARRAY = new IMenuableDef[0];
8 -
9 - public static class Helper {
10 - public static IMenuableDef[] deNull( IMenuableDef[] pCommands ) {
11 - int zCount = Objects.getNonNullEntryCount( pCommands );
12 - if ( (zCount == 0) ) {
13 - return EMPTY_ARRAY;
14 - }
15 - if ( (pCommands.length == zCount) ) {
16 - return pCommands;
17 - }
18 - IMenuableDef[] rv = new IMenuableDef[zCount];
19 - int ri = 0;
20 - for ( int i = 0; i < pCommands.length; ) {
21 - rv[ri++] = pCommands[i++];
22 - }
23 - return rv;
24 - }
25 - }
26 - }
1 + // This Source Code is in the Public Domain per: http://unlicense.org
2 + package org.litesoft.GWT.client;
3 +
4 + import org.litesoft.commonfoundation.typeutils.*;
5 +
6 + public interface IMenuableDef {
7 + public static final IMenuableDef[] EMPTY_ARRAY = new IMenuableDef[0];
8 +
9 + public static class Helper {
10 + public static IMenuableDef[] deNull( IMenuableDef[] pCommands ) {
11 + int zCount = Objects.getNonNullEntryCount( pCommands );
12 + if ( (zCount == 0) ) {
13 + return EMPTY_ARRAY;
14 + }
15 + if ( (pCommands.length == zCount) ) {
16 + return pCommands;
17 + }
18 + IMenuableDef[] rv = new IMenuableDef[zCount];
19 + int ri = 0;
20 + for ( int i = 0; i < pCommands.length; ) {
21 + rv[ri++] = pCommands[i++];
22 + }
23 + return rv;
24 + }
25 + }
26 + }