Skip to content

Commit

Permalink
I18N
Browse files Browse the repository at this point in the history
  • Loading branch information
cnfree committed May 27, 2016
1 parent 6d9a9fd commit fe75728
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ public void decompile( String root, String classPackage, String className )
true,
new LazyLoader( null ) );
structClass.releaseResources( );
classPackage = structClass.qualifiedName.replace( "/"
+ className.replaceAll( "(?i)\\.class", "" ), "" );
classPackage = structClass.qualifiedName.replace( "/" //$NON-NLS-1$
+ className.replaceAll( "(?i)\\.class", "" ), "" ); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}

FileUtil.zipDir( workingDir, classPackage, zipFileName );
Expand All @@ -90,7 +90,7 @@ public void decompile( String root, String classPackage, String className )
}

source = mapper.decompile( zipFileName,
( classPackage.length( ) > 0 ? ( classPackage + "/" ) : "" )
( classPackage.length( ) > 0 ? ( classPackage + "/" ) : "" ) //$NON-NLS-1$ //$NON-NLS-2$
+ className );

zipFile.delete( );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -191,19 +191,19 @@ public static String getUpdateUrl( Class nodeClass, IProgressMonitor monitor ) t

Object node = nodeClass.newInstance( );

ReflectionUtils.invokeMethod( node, "setId", new Class[]{
ReflectionUtils.invokeMethod( node, "setId", new Class[]{ //$NON-NLS-1$
String.class
}, new Object[]{
"472922"
"472922" //$NON-NLS-1$
} );

node = ReflectionUtils.invokeMethod( service, "getNode", new Class[]{
node = ReflectionUtils.invokeMethod( service, "getNode", new Class[]{ //$NON-NLS-1$
nodeClass, IProgressMonitor.class
}, new Object[]{
node, monitor
} );

return (String) ReflectionUtils.invokeMethod( node, "getUpdateurl", new Class[]{}, new Object[]{} );
return (String) ReflectionUtils.invokeMethod( node, "getUpdateurl", new Class[]{}, new Object[]{} ); //$NON-NLS-1$
}

private String getVersion( OSGiVersion remoteVersion )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public Set<CatalogItem> getSelectedCatalogItems( )
items.add( getEntryItem( entry ) );
}
}
ReflectionUtils.setFieldValue( entry, "operation", Operation.CHANGE );
ReflectionUtils.setFieldValue( entry, "operation", Operation.CHANGE ); //$NON-NLS-1$
}
}
return Collections.unmodifiableSet( items );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,12 +167,12 @@ private boolean requestFromJavadocHover( )
StackTraceElement[] stacks = Thread.currentThread( ).getStackTrace( );
for ( int i = 0; i < stacks.length; i++ )
{
if ( stacks[i].getClassName( ).indexOf( "BinaryType" ) != -1
&& stacks[i].getMethodName( ).equals( "getJavadocRange" ) )
if ( stacks[i].getClassName( ).indexOf( "BinaryType" ) != -1 //$NON-NLS-1$
&& stacks[i].getMethodName( ).equals( "getJavadocRange" ) ) //$NON-NLS-1$
return false;

if ( stacks[i].getClassName( ).indexOf( "JavadocHover" ) != -1
&& stacks[i].getMethodName( ).equals( "getHoverInfo" ) )
if ( stacks[i].getClassName( ).indexOf( "JavadocHover" ) != -1 //$NON-NLS-1$
&& stacks[i].getMethodName( ).equals( "getHoverInfo" ) ) //$NON-NLS-1$
return true;
}
return false;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ public void decompile( String root, String packege, String className )
mapOptions.put( IFernflowerPreferences.REMOVE_SYNTHETIC, "1" ); //$NON-NLS-1$
mapOptions.put( IFernflowerPreferences.DECOMPILE_GENERIC_SIGNATURES,
"1" ); //$NON-NLS-1$
mapOptions.put( IFernflowerPreferences.DECOMPILE_INNER, "1" );
mapOptions.put( IFernflowerPreferences.DECOMPILE_ENUM, "1" );
mapOptions.put( IFernflowerPreferences.DECOMPILE_INNER, "1" ); //$NON-NLS-1$
mapOptions.put( IFernflowerPreferences.DECOMPILE_ENUM, "1" ); //$NON-NLS-1$
mapOptions.put( IFernflowerPreferences.LOG_LEVEL,
IFernflowerLogger.Severity.ERROR.name( ) );
mapOptions.put( IFernflowerPreferences.ASCII_STRING_CHARACTERS, "1" ); //$NON-NLS-1$
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ public String toString( )
- line_separator.length( ) )
{
realignOutput.replace( index, index
+ line_separator.length( ), "" );
+ line_separator.length( ), "" ); //$NON-NLS-1$

for ( int j = 0; j < beforeLines.size( ); j++ )
{
Expand Down Expand Up @@ -370,7 +370,7 @@ private String getLineNumber( int i, int lineNumberWidth )
if ( i == -1 )
{
width = 0;
number = "";
number = ""; //$NON-NLS-1$
}
if ( width < lineNumberWidth )
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ public static void zipDir( File dir, String classPackage, String zipFile )
File file = files[i];
if(file.isDirectory( ))
continue;
ze = new ZipEntry( ( classPackage.length( ) > 0 ? ( classPackage + "/" ) : "" ) + file.getName( ) ); //$NON-NLS-1$
ze = new ZipEntry( ( classPackage.length( ) > 0 ? ( classPackage + "/" ) : "" ) + file.getName( ) ); //$NON-NLS-1$ //$NON-NLS-2$
ze.setSize( file.length( ) );
ze.setTime( file.lastModified( ) );
zos.putNextEntry( ze );
Expand Down

0 comments on commit fe75728

Please sign in to comment.