Skip to content

Commit

Permalink
Rebase on master
Browse files Browse the repository at this point in the history
  • Loading branch information
Michail-Antropov committed Sep 16, 2024
1 parent 8a8a187 commit 12b2163
Show file tree
Hide file tree
Showing 10 changed files with 173 additions and 404 deletions.
287 changes: 0 additions & 287 deletions data_model/1.3/clusters/EnergyCalendar.xml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -33408,10 +33408,10 @@ public void onSuccess(byte[] tlv) {
public static class EnergyCalendarCluster extends BaseChipCluster {
public static final long CLUSTER_ID = 154L;

private static final long CALENDAR_I_D_ATTRIBUTE_ID = 0L;
private static final long CALENDAR_ID_ATTRIBUTE_ID = 0L;
private static final long NAME_ATTRIBUTE_ID = 1L;
private static final long PROVIDER_I_D_ATTRIBUTE_ID = 2L;
private static final long EVENT_I_D_ATTRIBUTE_ID = 3L;
private static final long PROVIDER_ID_ATTRIBUTE_ID = 2L;
private static final long EVENT_ID_ATTRIBUTE_ID = 3L;
private static final long START_DATE_ATTRIBUTE_ID = 4L;
private static final long CALENDAR_PERIODS_ATTRIBUTE_ID = 5L;
private static final long SPECIAL_DAYS_ATTRIBUTE_ID = 6L;
Expand Down Expand Up @@ -33503,28 +33503,28 @@ public interface AttributeListAttributeCallback extends BaseAttributeCallback {

public void readCalendarIDAttribute(
CalendarIDAttributeCallback callback) {
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, CALENDAR_I_D_ATTRIBUTE_ID);
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, CALENDAR_ID_ATTRIBUTE_ID);

readAttribute(new ReportCallbackImpl(callback, path) {
@Override
public void onSuccess(byte[] tlv) {
@Nullable Long value = ChipTLVValueDecoder.decodeAttributeValue(path, tlv);
callback.onSuccess(value);
}
}, CALENDAR_I_D_ATTRIBUTE_ID, true);
}, CALENDAR_ID_ATTRIBUTE_ID, true);
}

public void subscribeCalendarIDAttribute(
CalendarIDAttributeCallback callback, int minInterval, int maxInterval) {
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, CALENDAR_I_D_ATTRIBUTE_ID);
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, CALENDAR_ID_ATTRIBUTE_ID);

subscribeAttribute(new ReportCallbackImpl(callback, path) {
@Override
public void onSuccess(byte[] tlv) {
@Nullable Long value = ChipTLVValueDecoder.decodeAttributeValue(path, tlv);
callback.onSuccess(value);
}
}, CALENDAR_I_D_ATTRIBUTE_ID, minInterval, maxInterval);
}, CALENDAR_ID_ATTRIBUTE_ID, minInterval, maxInterval);
}

public void readNameAttribute(
Expand Down Expand Up @@ -33555,54 +33555,54 @@ public void onSuccess(byte[] tlv) {

public void readProviderIDAttribute(
ProviderIDAttributeCallback callback) {
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, PROVIDER_I_D_ATTRIBUTE_ID);
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, PROVIDER_ID_ATTRIBUTE_ID);

readAttribute(new ReportCallbackImpl(callback, path) {
@Override
public void onSuccess(byte[] tlv) {
@Nullable Long value = ChipTLVValueDecoder.decodeAttributeValue(path, tlv);
callback.onSuccess(value);
}
}, PROVIDER_I_D_ATTRIBUTE_ID, true);
}, PROVIDER_ID_ATTRIBUTE_ID, true);
}

public void subscribeProviderIDAttribute(
ProviderIDAttributeCallback callback, int minInterval, int maxInterval) {
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, PROVIDER_I_D_ATTRIBUTE_ID);
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, PROVIDER_ID_ATTRIBUTE_ID);

subscribeAttribute(new ReportCallbackImpl(callback, path) {
@Override
public void onSuccess(byte[] tlv) {
@Nullable Long value = ChipTLVValueDecoder.decodeAttributeValue(path, tlv);
callback.onSuccess(value);
}
}, PROVIDER_I_D_ATTRIBUTE_ID, minInterval, maxInterval);
}, PROVIDER_ID_ATTRIBUTE_ID, minInterval, maxInterval);
}

public void readEventIDAttribute(
EventIDAttributeCallback callback) {
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, EVENT_I_D_ATTRIBUTE_ID);
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, EVENT_ID_ATTRIBUTE_ID);

readAttribute(new ReportCallbackImpl(callback, path) {
@Override
public void onSuccess(byte[] tlv) {
@Nullable Long value = ChipTLVValueDecoder.decodeAttributeValue(path, tlv);
callback.onSuccess(value);
}
}, EVENT_I_D_ATTRIBUTE_ID, true);
}, EVENT_ID_ATTRIBUTE_ID, true);
}

public void subscribeEventIDAttribute(
EventIDAttributeCallback callback, int minInterval, int maxInterval) {
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, EVENT_I_D_ATTRIBUTE_ID);
ChipAttributePath path = ChipAttributePath.newInstance(endpointId, clusterId, EVENT_ID_ATTRIBUTE_ID);

subscribeAttribute(new ReportCallbackImpl(callback, path) {
@Override
public void onSuccess(byte[] tlv) {
@Nullable Long value = ChipTLVValueDecoder.decodeAttributeValue(path, tlv);
callback.onSuccess(value);
}
}, EVENT_I_D_ATTRIBUTE_ID, minInterval, maxInterval);
}, EVENT_ID_ATTRIBUTE_ID, minInterval, maxInterval);
}

public void readStartDateAttribute(
Expand Down
Loading

0 comments on commit 12b2163

Please sign in to comment.