slice2java(1)
π slice2java β the Slice β Java compiler, bestie edition π
okay so you know how sometimes you just need your Slice files to become Java? yeah. that's this. it's a General Commands Manual page, she's slice2java(1), and she ate fr fr. let's get into it π«Ά
β¨ NAME β¨
slice2java β the Slice to Java compiler. that's it, that's the whole vibe. π
β¨ SYNOPSIS β¨
slice2java [options] [files]
literally just throw your options and your files at her and she'll do the thing π
β¨ DESCRIPTION β¨
so slice2java compiles Slice files to Java. no cap. and while she's doing that compilation, the macro __SLICE2JAVA__ gets defined. that's important, write it down. π
the full tea β like, the complete documentation for slice2java β lives online at:
(yeah it's a long one, she's giving very detailed URL energy, we love that for her πΈ)
β¨ OPTIONS β¨
every single one, in order, no skips, we don't do that here π
-h,--helpβ shows you a help message. when in doubt, ask for help, it's not embarrassing it's iconic.-v,--versionβ tells you which compiler version you're on. know your queen's era. π-DNAMEβ defines the preprocessor symbolNAME. justNAME. no value. bare.-DNAME=DEFβ defines the preprocessor symbolNAMEand gives it the valueDEF. now she has range. β¨-UNAMEβ undefines the preprocessor symbolNAME. un-defining. closure. we support it. π¦-IDIRβ adds the directoryDIRto the search path for#includedirectives. so when your includes go looking, they know where to look. bestie behavior fr.-Eβ prints the preprocessor output onstdout. raw, unfiltered, no code generation, just the preprocessed truth.--output-dir DIRβ drops all the generated files into directoryDIR. tidy. organized. main character energy. π-d,--debugβ prints debug information showing what the Slice parser is doing, operation by operation. not me watching the parser think π--dependβ prints dependency information to standard output by default, or to the file given by--depend-fileif you specified that. and listen: no code is generated when this option is on. zero. none. she's just here for the deps. π--depend-xmlβ same deal but the dependency info comes out in XML format, to standard output by default, or to the file from--depend-file. and again, no code is generated when this option is specified. periodt.--depend-file FILEβ sends your dependency information to the fileFILE. what format you get depends on whether--dependor--depend-xmlis also in the mix. they work together, it's a collab. π€--validateβ checks that the command-line options you provided are correct, and generates absolutely no code. just a vibe check on your flags. β--compatβ generates code for the Java Compat mapping. when you use this one, the macro__SLICE2JAVA_COMPAT__gets defined during compilation. if you don't use it, the default behavior is to generate code for the Java mapping. choose your fighter. βοΈ--tieβ generates tie classes. heads up: (Java Compat only) π--implβ generates sample implementation files. important: this option will not overwrite an existing file. she's respectful like that. π--impl-tieβ generates sample implementation files using tie classes, and same deal, it will not overwrite an existing file. also (Java Compat only) π¦--checksum CLASSβ generates checksums for Slice definitions and puts them into the classCLASS. the class name you give can optionally include a package specifier, so go off. the generated class holds checksums for all of the Slice files being translated by this invocation of the compiler. all of them. every single one. β¨--meta METAβ defines the file metadata directiveMETA. using this option is equivalent to defining the file metadataMETAin each named Slice file, and in any file included by a named Slice file. and here's the kicker: file metadata specified with--metaoverrides any corresponding file metadata directive in the files being compiled. she said mine now. π--list-generatedβ emits a list of generated files, in XML format. cute little receipt of everything she made. π§Ύ
π side note bestie:--dependand--depend-xmlboth mean no code gets generated, and--validatealso generates nothing. don't be surprised when the output dir is empty, it's not a bug it's the design. π
β¨ SEE ALSO β¨
her whole friend group, go say hi π―ββοΈ
slice2cpp(1)slice2cs(1)slice2js(1)slice2matlab(1)slice2objc(1)slice2php(1)slice2py(1)slice2rb(1)slice2swift(1)
that's the whole page, you understood it, I'm so proud of you π₯Ήπ this was slice2java(1), straight out of the General Commands Manual, and that's the sign-off β slice2java(1), periodt. go compile something gorgeous. πΈπ¦β¨
π¦ where this page comes from
- arch rolling: zeroc-ice 3.7.10-3 Β· GPL-2.0-only AND LicenseRef-ICE
- debian bookworm: zeroc-ice-compilers 3.7.8-2.1+b1 Β· GPL-2.0+exceptions
- debian trixie: zeroc-ice-compilers 3.7.10-3.1 Β· GPL-2.0+exceptions
- ubuntu jammy: zeroc-ice-compilers 3.7.6-4ubuntu1 Β· GPL-2.0+exceptions
- ubuntu noble: zeroc-ice-compilers 3.7.10-2.1build1 Β· GPL-2.0+exceptions
- ubuntu questing: zeroc-ice-compilers 3.7.10-3.1
- ubuntu resolute: zeroc-ice-compilers 3.7.10-4build2 Β· GPL-2.0+exceptions
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms