GroupDocs.Metadata for Java adalah solusi manipulasi bidang metadata lanjutan untuk dengan mudah membaca, menambah, memodifikasi, menghapus, mencari, membandingkan, mengganti, dan mengekspor informasi metadata dari gambar dan format dokumen tanpa menggunakan perangkat lunak eksternal apa pun. Edit detail metadata dari Word dokumen, Excel spreadsheet, PowerPoint presentasi, Outlook email, OneNote, Visio, Project, PDF, AutoCAD, Zip, Audio dan Video format file bersama dengan dukungan untuk bekerja dengan banyak fitur pemrosesan metadata lainnya.
GroupDocs.Metadata for Java memudahkan pengembang Java untuk mengedit detail metadata ke file WEBP dari dalam aplikasi mereka dengan menerapkan beberapa langkah mudah.
GroupDocs.Metadata for Java API didukung di semua platform utama dan sistem operasi. Sebelum menjalankan kode di bawah ini, pastikan bahwa Anda memiliki prasyarat berikut diinstal pada sistem Anda.
public class UpdatingMetadata
{
public static void run()
{
Date threeDaysAgo = new Date(System.currentTimeMillis() - TimeUnit.DAYS.toMillis(3));
try (Metadata metadata = new Metadata("input.webp"))
{
// Perbarui tanggal/waktu pembuatan file jika nilai yang ada lebih tua dari 3 hari
int affected = metadata.updateProperties(new ContainsTagSpecification(Tags.getTime().getCreated()).and(
new OfTypeSpecification(MetadataPropertyType.DateTime)).and(
new UpdatingMetadata().new DateBeforeSpecification(threeDaysAgo)), new PropertyValue(new Date()));
System.out.println(String.format("Affected properties: %s", affected));
metadata.save("output.webp");
}
}
// Tentukan spesifikasi Anda sendiri untuk memfilter properti metadata
public class DateBeforeSpecification extends Specification
{
public DateBeforeSpecification(Date date)
{
setValue(date);
}
public final Date getValue()
{
return auto_Value;
}
private void setValue(Date value)
{
auto_Value = value;
}
private Date auto_Value;
public boolean isSatisfiedBy(MetadataProperty candidate)
{
Date date = candidate.getValue().toClass(Date.class);
if (date != null)
{
return date.before(getValue());
}
return false;
}
}
}
Perbarui informasi metadata ke file WEBP sekarang dengan mengunjungi situs web GroupDocs.Metadata Live Demos. Demo langsung memiliki manfaat sebagai berikut.
Tidak perlu mengunduh API
Tidak perlu menulis kode apa pun
Cukup unggah file sumbernya
Dapatkan tautan unduhan untuk menyimpan file
Dokumen multi format dan API pengeditan metadata gambar untuk Java. Ambil metadata dari beberapa format file populer seperti yang dinyatakan di bawah ini.
(Zipped File)
(Excel Template)
(Excel Macro-Enabled Template)
(Excel 97 - 2003 Template)
(Open XML Workbook)
(Macro-enabled Spreadsheet)
(Excel Binary Workbook)
(Microsoft Excel Spreadsheet (Legacy))
(Windows Metafile)
(WAVE Audio File)
(Visio Stencil XML File)
(Visio Stencil File)
(Visio Drawing)
(Visio Drawing File)
(The 7th Guest Video File)
(vCard File)
(TrueType Font)
(TrueType Font Collection)
(Tagged Image File Format)
(Photoshop Document)
(Open XML presentation Format)
(Macro-enabled Presentation File)
(Microsoft PowerPoint 97-2003)
(PowerPoint Slide Show)
(Macro-enabled Slide Show)
(PowerPoint Slide Show)
(Microsoft PowerPoint Template Presentation)
(Microsoft PowerPoint Template File)
(Microsoft PowerPoint Template Files)
(Portable Network Graphic)
(Portable Document Format)
(OpenType Font)
(OpenDocument Text File Format)
(OpenDocument Spreadsheet)
(Outlook Message Item File)
(Microsoft Project Template)
(Microsoft Project File)
(MP3 Audio File)
(Apple QuickTime Movie)
(JPEG 2000 Image)
(Joint Photographic Expert Group Image)
(JPEG 2000 Core Image)
(High Efficiency Image Format)
(High Efficiency Image Format)
(Graphical Interchange Format)
(Flash Video File)
(Open eBook File)
(E-Mail Message)
(Enhanced Metafile Format)
(Autodesk Drawing Exchange Format)
(AutoCAD Drawing File)
(Microsoft Word Template File )
(Microsoft Word 2007+ Template File)
(Microsoft Word Template Files)
(Office 2007+ Word Document)
(Microsoft Word 2007 Marco File)
(Microsoft Word Binary Format)
(Graphics File Format)
(Digital Imaging and Communications in Medicine)
(DICOM Image)
(Bitmap Image File)
(Audio Video Interleave File)
(Advanced Systems Format File)
(Matroska Video File)
(OneNote Document)
(Graphics File Format)