Package de.mhus.lib.core.crypt.pem
Class PemBlockModel
- java.lang.Object
-
- de.mhus.lib.core.MLog
-
- de.mhus.lib.core.lang.MObject
-
- de.mhus.lib.core.AbstractProperties
-
- de.mhus.lib.core.MProperties
-
- de.mhus.lib.core.crypt.pem.PemBlockModel
-
- All Implemented Interfaces:
PemBlock,ILog,IProperties,IReadProperties,MNlsProvider,Nls,Externalizable,Serializable,Iterable<Map.Entry<String,Object>>,Map<String,Object>
- Direct Known Subclasses:
PemKey
public class PemBlockModel extends MProperties implements PemBlock
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected Stringblock-
Fields inherited from class de.mhus.lib.core.MProperties
properties
-
Fields inherited from interface de.mhus.lib.core.crypt.pem.PemBlock
BLOCK_CIPHER, BLOCK_CONTENT, BLOCK_HASH, BLOCK_PRIV, BLOCK_PUB, BLOCK_SIGN, CREATED, DESCRIPTION, EMBEDDED, ENC_BLOWFISH, ENCRYPTED, FORMAT, IDENT, KEY_ID, LENGTH, METHOD, PRIV_ID, PUB_ID, STRING_ENCODING, SYMMETRIC
-
-
Constructor Summary
Constructors Constructor Description PemBlockModel()PemBlockModel(PemBlock clone)PemBlockModel(String name)PemBlockModel(String name, byte[] block)PemBlockModel(String name, String block)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetBlock()Returns the Block content without placeholders.byte[]getBytesBlock()StringgetEncodedBlock()StringgetName()Returns the name of the blockStringgetRest()PemBlockModelparse(String block)<T extends PemBlockModel>
Tset(String key, Object value)<T extends PemBlockModel>
TsetBlock(byte[] bytes)<T extends PemBlockModel>
TsetBlock(String block)protected voidsetName(String name)StringtoString()-
Methods inherited from class de.mhus.lib.core.MProperties
appendToMap, appendToMap, clear, containsValue, entrySet, explodeToMProperties, explodeToMProperties, explodeToMProperties, explodeToMProperties, explodeToMProperties, explodeToOptions, explodeToOptions, explodeToOptions, explodeToProperties, getProperty, isEditable, isFunctional, isProperty, keys, load, load, load, load, loadOrEmpty, putAll, readExternal, removeProperty, save, save, setProperty, size, toIProperties, toMProperties, updateFunctional, values, writeExternal
-
Methods inherited from class de.mhus.lib.core.AbstractProperties
containsKey, get, getBoolean, getBoolean, getCalendar, getDate, getDouble, getFloat, getFormatted, getInt, getLong, getNumber, getString, getString, isEmpty, iterator, keySet, put, putAll, putReadProperties, remove, setBoolean, setCalendar, setDate, setDouble, setFloat, setInt, setLong, setNumber, setString, toMap
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface de.mhus.lib.core.IReadProperties
containsKey, containsValue, entrySet, get, getBoolean, getBoolean, getCalendar, getDate, getDouble, getFloat, getInt, getLong, getNumber, getProperty, getString, getString, isProperty, keys, values
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
-
-
-
-
Field Detail
-
block
protected String block
-
-
Method Detail
-
parse
public PemBlockModel parse(String block) throws ParseException
- Throws:
ParseException
-
getRest
public String getRest()
-
setName
protected void setName(String name)
-
getName
public String getName()
Description copied from interface:PemBlockReturns the name of the block
-
getBlock
public String getBlock()
Description copied from interface:PemBlockReturns the Block content without placeholders.
-
setBlock
public <T extends PemBlockModel> T setBlock(String block)
-
set
public <T extends PemBlockModel> T set(String key, Object value)
-
toString
public String toString()
- Overrides:
toStringin classMProperties
-
getEncodedBlock
public String getEncodedBlock()
-
setBlock
public <T extends PemBlockModel> T setBlock(byte[] bytes)
-
getBytesBlock
public byte[] getBytesBlock()
- Specified by:
getBytesBlockin interfacePemBlock
-
-