io.qt.internal.MetaDataAttributes Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of qtjambi Show documentation
Show all versions of qtjambi Show documentation
QtJambi base module containing QtCore, QtGui and QtWidgets.
package io.qt.internal;
import io.qt.*;
/**
* @hidden
*/
public final class MetaDataAttributes extends QFlags<@NonNull MetaDataFlags> implements Comparable<@NonNull MetaDataAttributes> {
private static final long serialVersionUID = 0xdcbd64d87c9583f2L;
static {
QtJambi_LibraryUtilities.initialize();
}
/**
* Creates a new MetaDataAttributes where the flags in args
are set.
* @param args enum entries
*/
public MetaDataAttributes(@Nullable MetaDataFlags @NonNull... args){
super(args);
}
/**
* Creates a new MetaDataAttributes with given value
.
* @param value
*/
public MetaDataAttributes(int value) {
super(value);
}
/**
* Combines this flags with enum entry.
* @param e enum entry
* @return new MetaDataAttributes
*/
@Override
public final @NonNull MetaDataAttributes combined(@StrictNonNull MetaDataFlags e){
return new MetaDataAttributes(value() | e.value());
}
/**
* Sets the flag e
* @param e enum entry
* @return this
*/
public final @NonNull MetaDataAttributes setFlag(@Nullable MetaDataFlags e){
return setFlag(e, true);
}
/**
* Sets or clears the flag flag
* @param e enum entry
* @param on set (true) or clear (false)
* @return this
*/
public final @NonNull MetaDataAttributes setFlag(@Nullable MetaDataFlags e, boolean on){
if (e!=null) {
if (on) {
setValue(value() | e.value());
}else {
setValue(value() & ~e.value());
}
}
return this;
}
/**
* Returns an array of flag objects represented by this MetaDataAttributes.
* @return array of enum entries
*/
@Override
public final @NonNull MetaDataFlags @NonNull[] flags(){
return super.flags(MetaDataFlags.values());
}
/**
* {@inheritDoc}
*/
@Override
public final @NonNull MetaDataAttributes clone(){
return new MetaDataAttributes(value());
}
/**
* Compares this flag with the specified flag for order.
* {@inheritDoc}
*/
@Override
public final int compareTo(@StrictNonNull MetaDataAttributes other){
return Integer.compare(value(), other.value());
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy